Xcode 7 GM不能提交(GIT)
每当我尝试提交,在Xcode使用源代码控制,我得到一个错误,我需要configuration我的电子邮件地址和名称(似乎读我的电子邮件地址不正确)。 我去了docker,再次进入了他们。 错误没有消失。
我可以在terminal正常提交,但不能在Xcode。 有没有办法解决它? 或者直接在Xcode中inputconfiguration信息?
这是错误信息:
***请告诉我你是谁。
跑
git config --global user.email "you@example.com" git config --global user.name "Your Name"
设置您的帐户的默认身份。
省略–global仅在此存储库中设置标识。致命:无法自动检测电子邮件地址(得到'myemail @ gmail-1040826。(none)')
这里是我的.gitconfig(我用“我的名字”取代了我的实际名称,而我的用户名用“myname”出于隐私原因):
myname-1040826:Project myname$ git config -l user.email=myname@gmail.com user.name=My Name filter.media.clean=git-media-clean %f filter.media.smudge=git-media-smudge %f core.repositoryformatversion=0 core.filemode=true core.bare=false core.logallrefupdates=true core.ignorecase=true core.precomposeunicode=true submodule.PeerKit.url=https://github.com/jpsim/PeerKit.git
它看起来像Xcode不读全球GIT设置。 如果遇到此问题,请通过terminal将您的姓名和电子邮件设置为特定项目:
git config user.email "you@example.com" git config user.name "Your Name"
注意:当你这样做时,确保你在项目的目录中。
这不仅是全球环境的问题,真正的问题是地方问题。
尝试这个。
cd你的/项目/目录
git config –local user.email“your@email.com”
git config –local user.name“yourName”
这对我有效。