我试图提交到我的Github仓库,但是我一直收到一个错误消息,要求我通过电子邮件和姓名登录来确认身份。我正在使用ssh进行提交,我的ssh配置和密钥已经正确配置。我还检查了gitconfig文件,它们似乎也是正确的。有什么想法吗?
最初的回答:
您需要在本地计算机上设置Git用户信息。请尝试在终端中运行以下命令:
git config --global user.email "your_email@example.com"
git config --global user.name "Your Name"
###Gitconfig file
[core]
repositoryformatversion = 0
filemode = false
bare = false
logallrefupdates = true
symlinks = false
ignorecase = true
[remote "origin"]
url = git@github.com:imran1005/testhomere.git
fetch = +refs/heads/*:ref
[branch "master"]
remote = origin
merge = refs/heads/master
###Error msg on console win7 cmd while executing git commit:
*** Please tell me who you are.
Run
git config --global user.email "you@example.com"
git config --global user.name "Your Name"
to set your account's default identity.
Omit --global to set the identity only in this repository.
fatal: unable to auto-detect email address (got 'TestUser@Asus.(none)')
git config
开头的两行中填写你的个人信息。 - ferrix