亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

directory search
Guides gitattributes giteveryday gitglossary gitignore gitmodules gitrevisions gittutorial gitworkflows Administration git archive git bundle git clean git filter-branch git fsck git gc git instaweb git reflog Basic Snapshotting git add git commit git diff git mv git reset git rm git status Branching and Merging git branch git checkout git log git merge git mergetool git stash git tag Debugging git bisect git blame git grep Email git am git format-patch git request-pull git send-email External Systems git fast-import git svn Getting and Creating Projects git clone git init Git git annotate git archimport git bisect-lk2009 git check-attr git check-mailmap git check-ref-format git checkout-index git cherry git citool git column git credential git credential-cache git credential-store git cvsexportcommit git cvsimport git cvsserver git diff-files git diff-tree git difftool git fast-export git fetch-pack git fmt-merge-msg git get-tar-commit-id git gui git http-backend git http-fetch git http-push git imap-send git index-pack git interpret-trailers git ls-remote git ls-tree git mailinfo git mailsplit git merge-file git merge-index git merge-one-file git merge-tree git mktag git mktree git name-rev git notes git p4 git pack-objects git pack-redundant git pack-refs git parse-remote git patch-id git prune git prune-packed git quiltimport git receive-pack git remote-ext git remote-fd git remote-testgit git repack git replace git rerere git send-pack git sh-i18n git sh-setup git shell git show-branch git show-index git stripspace git unpack-file git unpack-objects git upload-archive git upload-pack git var git verify-commit git verify-tag git whatchanged git worktree Inspection and Comparison git describe git shortlog git show Miscellaneous api credentials api index gitcli gitcore tutorial gitcredentials gitcvs migration gitdiffcore githooks gitk gitnamespaces gitremote helpers gitrepository layout gitsubmodules gittutorial 2 gitweb gitweb.conf pack format User Manual Patching git apply git cherry-pick git rebase git revert Plumbing Commands git cat-file git check-ignore git commit-tree git count-objects git diff-index git for-each-ref git hash-object git ls-files git merge-base git read-tree git rev-list git rev-parse git show-ref git symbolic-ref git update-index git update-ref git verify-pack git write-tree Server Admin git daemon git update-server-info Setup and Config git git config git help Sharing and Updating Projects git fetch git pull git push git remote git submodule
characters

名稱

git-shell  - 僅限 Git-SSH 訪問的受限登錄 shell

概要

chsh -s $(command -v git-shell) <user>git clone <user>@localhost:/path/to/repo.git
ssh <user>@localhost

描述

這是 SSH 帳戶的登錄外殼,用于提供受限制的 Git 訪問。它只允許執(zhí)行實(shí)現(xiàn)拉/推功能的服務(wù)器端 Git 命令,以及git-shell-commands在用戶主目錄中命名的子目錄中存在的自定義命令。

命令

git shell-c選項(xiàng)后接受以下命令:

git receive-pack <argument>   git upload-pack <argument>   git upload-archive <argument>

調(diào)用相應(yīng)的服務(wù)器端命令,以支持客戶端的git push,git fetchgit archive --remote請求。

cvs server

模仿 CVS 服務(wù)器。參見 git-cvsserver [1]。

如果存在~/git-shell-commands目錄,則git shell還將通過在用戶的主目錄中運(yùn)行“ git-shell-commands/<command> <arguments>”來處理其他自定義命令。

交互式使用

默認(rèn)情況下,上述命令只能使用該-c選項(xiàng)執(zhí)行; 該 shell 不是交互式的。

如果~/git-shell-commands目錄存在,git shell也可以交互式運(yùn)行(不帶參數(shù))。如果目錄中help存在命令git-shell-commands,則會向用戶提供允許的操作概述。然后出現(xiàn)一個(gè)“git>”提示符,用戶可以輸入git-shell-commands目錄中的任何命令或exit關(guān)閉連接。

通常,此模式用作管理界面,以允許用戶列出他們有權(quán)訪問的存儲庫,創(chuàng)建,刪除或重命名存儲庫,或更改存儲庫描述和權(quán)限。

如果no-interactive-login命令存在,則運(yùn)行它并交互式 shell 被中止。

示例

To disable interactive logins, displaying a greeting instead:

$ chsh -s /usr/bin/git-shell
$ mkdir $HOME/git-shell-commands
$ cat >$HOME/git-shell-commands/no-interactive-login <<\EOF
#!/bin/sh
printf '%s\n' "Hi $USER! You've successfully authenticated, but I do not"printf '%s\n' "provide interactive shell access."exit 128EOF
$ chmod +x $HOME/git-shell-commands/no-interactive-login

要啟用 git-cvsserver 訪問權(quán)限(通常應(yīng)該有上述no-interactive-login示例作為先決條件,因?yàn)閯?chuàng)建 git-shell-commands 目錄允許交互式登錄):

$ cat >$HOME/git-shell-commands/cvs <<\EOFif ! test $# = 1 && test "$1" = "server"then
        echo >&2 "git-cvsserver only handles \"server\""
        exit 1fi
exec git cvsserver server
EOF
$ chmod +x $HOME/git-shell-commands/cvs
Previous article: Next article: