错误:git-credential-osxkeychain 死于信号 11 - 无法理解答案



我试图将一个文本文件推送到github,但收到了上述错误。我正在使用OSX 10.7.5git-1.8.4.2

我已经创建了一个文本文件,我似乎可以毫无问题地添加和提交。在我的第一次尝试中,我收到了以下错误消息:

warning: push.default is unset; its implicit value is changing in
Git 2.0 from 'matching' to 'simple'. To squelch this message
and maintain the current behavior after the default changes, use:
git config --global push.default matching
To squelch this message and adopt the new behavior now, use:
git config --global push.default simple
See 'git help config' and search for 'push.default' for further information.
(the 'simple' mode was introduced in Git 1.7.11. Use the similar mode
'current' instead of 'simple' if you sometimes use older versions of Git)
error: `git-credential-osxkeychain died of signal 11`
Username for `'https://github.com'`: Anto58
Password for `'https://Anto58@github.com'`: 
error: `git-credential-osxkeychain` died of signal 11
To `https://github.com/Anto58/datasciencecoursera.git`
! [rejected]        master -> master (fetch first)
error: failed to push some refs to `'https://github.com/Anto58/datasciencecoursera.git'`
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.

我花了一些时间对此进行研究,发现这是一个问题,因为我的githubrepo中有一个不在本地repo上的readme文件,并且我尝试实现这两种建议的解决方案,即在推送之前进行克隆和拉取。

克隆看起来好像在起作用:

Cloning into 'coursera-repo'...
remote: Counting objects: 3, done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 3 (delta 0), reused 0 (delta 0), pack-reused 0
Unpacking objects: 100% (3/3), done.
Checking connectivity... done

但我还是推不动。然后我删除了我的目录,并再次使用pull,它给出了几乎相同的输出:

remote: Counting objects: 3, done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 3 (delta 0), reused 0 (delta 0), pack-reused 0
Unpacking objects: 100% (3/3), done.
From `https://github.com/Anto58/datasciencecoursera`
* branch            master     -> FETCH_HEAD
* [new branch]      master     -> origin/master

但推送也有同样的问题:

error: `git-credential-osxkeychain` died of signal 11
Username for `'https://github.com'`: Anto58
Password for `'https://Anto58@github.com'`: 
error: `git-credential-osxkeychain` died of signal 11
Everything up-to-date 

虽然它说一切都是最新的,但该文件并没有出现在我的github'存储库中。

然后我找到了stackoverflow问题上的链接,该链接指向处理缓存github密码的网站,我试图遵循该链接。

我输入了

git credential-osxkeychain

这给了我与开始时相同的错误

然后,我尝试使用curl命令下载osxkeychain帮助程序:

`curl -s -O 
? https://github-media-downloads.s3.amazonaws.com/osx/git-dredential-osxkeychain` 

我没有收到错误消息,所以我认为它有效吗?

下一步是更改权限:

chmod u+x git-credential-osxkeychain

它再次没有给出错误消息

但我在下一步摔倒了:

sudo mv git-credential-osxkeychain 
"$(dirname $(which git))/git-credential-osxkeychain"`

在那里我得到了illegal variable name message。这是因为dirname实际上应该是/user/local/git/吗?"which git"也应该被其他东西取代吗?当我收到消息时,我开始非常紧张:

`WARNING: Improper use of the sudo command could lead to data loss
or the deletion of important system files. Please double-check your
typing when using sudo. Type "man sudo" for more information.`

因为我真的不知道自己在做什么。

Coursera上的TA建议只运行

git config --global credential.helper osxkeychain

但现在我收到两次错误消息,而不是一次,仍然无法推送。

我也试图找到我的gitconfig文件在哪里,因为其中一个建议是删除你的gitconfig文件,但只有在检查它没有其他内容之后。它没有出现在finder中的正常搜索中,所以我认为它是隐藏的,并使用了defaults write com.apple.finder AppleShowAllFiles YES,但没有成功。当我使用alt-Relaunch时,Finder会一直打开没有搜索选项的Git包窗口。

抱歉时间太长了-有人能帮我简单解释一下我需要做什么吗-假设我什么都不知道?

如果你能解释为什么这会非常有帮助,因为我想了解它是如何工作的。

我使用与您相同的Mac操作系统和Git版本,在尝试将HelloWorld.md文件推送到Github上的datasciencecursera repo时收到了相同的错误消息。我终于解决了这个问题,删除了Github上的repo并重新制作,但没有勾选create README文件,所以它只是一个完全空的存储库。然后,我删除并重新创建了我在本地计算机上创建的目录,重新制作了HelloWorld文件,并再次按照课程说明启动和链接本地/Github存储库,并将文件推送到Github。最后一个对我有用的命令是GitHub在我设置repo时建议的选项之一:git push-u origin master(链接到本地存储库后)。我仍然收到错误消息,并被要求提供我的用户名和密码。我输入了这些(注意,当你输入密码时,密码不会显示…),然后再次收到错误消息,但后面是详细信息:

错误:git凭据osxkeychain因信号11而死亡错误:git凭据osxkeychain因信号11而死亡计数对象:3个,完成。写入对象:100%(3/3),244字节|0字节/s,已完成。总计3(增量0),重复使用0(增量0到https://github.com/keh444/datasciencecoursera.git*【新建分支】master->master分支主机设置为从原点跟踪远程分支主机。

当我在GitHub上查看时,HelloWorld文件在repo中,所以它起了作用。

虽然从长远来看,这可能无法解决问题,但至少我现在可以继续…

最新更新