我已经通过ssh克隆了我的git存储库.因此,每次我通过推或拉与原始主人沟通时,我都必须重新输入密码.如何配置git以便我不需要多次输入密码?
我如何获得有关git/git-shell的一些调试信息?
我有一个问题,user1可以克隆存储库没有问题,而user2只能克隆一个空的.我设定了GIT_TRACE=1,但没有任何有用的东西被告知.
最后,经过长时间的反复试验,结果证明这是文件的权限问题.适当的错误消息可能会使此问题短路.
当我想连接到我的服务器这样的时候
ssh -a username@my-server.de -p 22
Run Code Online (Sandbox Code Playgroud)
它给了我两个错误消息:
PTY allocation request failed on channel 0
shell request failed on channel 0
Run Code Online (Sandbox Code Playgroud)
当我使用参数时-T,第一个错误消息消失了.但是如何修复第二个呢?我无法连接.对于其他服务器,我可以毫无问题地连接.
我在MAC OS 10.9上参数-v显示了这个调试输出:
OpenSSH_6.2p2, OSSLShim 0.9.8r 8 Dec 2011
debug1: Reading configuration data /etc/ssh_config
debug1: /etc/ssh_config line 20: Applying options for *
debug1: Connecting to xxx.your-server.de [188.40.3.15] port 22.
debug1: Connection established.
debug1: identity file /Users/xxx/.ssh/id_rsa type -1
debug1: identity file /Users/xxx/.ssh/id_rsa-cert type -1
debug1: identity file /Users/xxx/.ssh/id_dsa type -1
debug1: identity file /Users/xxx/.ssh/id_dsa-cert type …Run Code Online (Sandbox Code Playgroud) 我在win7工作并使用sshd设置git服务器.我git --bare init myapp.git,正确克隆ssh://git@localhost/home/git/myapp.git在Cywgin中.但是我需要再次使用Cygwin的配置git ,我想在Git Bash中使用 git clone .我跑步git clone ssh://git@localhost/home/git/myapp.git并获得以下信息
ssh_exchange_identification: Connection closed by remote host
Run Code Online (Sandbox Code Playgroud)
然后我ssh -vvv git@localhost在Git Bash中运行并获得消息
debug2: ssh_connect: needpriv 0
debug1: Connecting to localhost [127.0.0.1] port 22.
debug1: Connection established.
debug1: identity file /c/Users/MoreFreeze/.ssh/identity type -1
debug3: Not a RSA1 key file /c/Users/MoreFreeze/.ssh/id_rsa.
debug2: key_type_from_name: unknown key type '-----BEGIN'
debug3: key_read: missing keytype
debug3: key_read: missing whitespace
// above it …Run Code Online (Sandbox Code Playgroud) 我搜索了一会儿,但我无法找到解决问题的方法.
我有一个服务器,我可以通过ssh连接到用户名git和本地git存储库.
现在我想将本地存储库推送到服务器上新创建的存储库.
这是我做的:
/home/git/test.gitgit remote add test ssh://git@serverIp:/home/git/test.gitgit push test master我总是得到
fatal: could not read from remote repository
Please make sure you have the correct access rights
and the repository exists.
Run Code Online (Sandbox Code Playgroud)
我正在使用本地Windows 7机器,并希望上传到Linux服务器.
我可以通过ssh与git用户登录.我也尝试以root相同的结果作为用户(使事情工作一次).
我永远不会被问到ssh password.
我真的不知道我做错了什么.
在你称之为副本之前,我搜索了很多这个问题,似乎没有人谈论同样的问题.
更新:
昨天我创建了一个 ssh 密钥并克隆了一个用于工作的存储库。进行一些更改后,我尝试推送提交:
git push
ERROR: Repository not found.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Run Code Online (Sandbox Code Playgroud)
我已经阅读了这篇活跃的 SO 帖子。我的问题仍然存在。我不知道如何找出问题所在,因此将分享我认为相关的所有内容。
在我的笔记本电脑上,我有个人和工作存储库。我的工作工作位于嵌套在~/Documents/Projects/Zen/Projects/. 其他地方例如~/Documents/Projects/Personal/用于个人github。
我的 .gitconfig 看起来像这样:
[user]
email = 12345+doug@users.noreply.github.com
name = 12345doug
[includeIf "gitdir:/home/doug/Documents/Projects/Zen/"]
path = ~/.git-zen
Run Code Online (Sandbox Code Playgroud)
/.git-zen 看起来像这样:
[user]
email = doug@work.com
name = doug-work
Run Code Online (Sandbox Code Playgroud)
目前我在一个仓库中:
pwd
/home/doug/Documents/Projects/Zen/Projects/analytics-psql-action
Run Code Online (Sandbox Code Playgroud)
一些提交准备好推送:
~/Documents/Projects/Zen/Projects/analytics-psql-action$ git status
On branch master
Your branch is ahead of 'origin/master' by …Run Code Online (Sandbox Code Playgroud) git ×5
ssh ×5
debugging ×1
git-remote ×1
github ×1
pty ×1
repository ×1
ssh-keys ×1
terminal ×1
trace ×1