【发布时间】:2017-02-20 02:36:54
【问题描述】:
在我添加 ssh 密钥并检查它是否已成功验证后,我正在为 git 使用 ssh 密钥。但是我还是不能提交代码
$ eval "$(ssh-agent -s)"
Agent pid 2599
$ ssh-add ~/id_rsa
Identity added: /home/vagrant/id_rsa (/home/vagrant/id_rsa)
$ssh -T git@github.com
Hi my-git-username! You've successfully authenticated, but GitHub does not provide shell access.
但我不能提交
$ git commit -m "Develop Dockerfile for shopContainer"
*** 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 'vagrant@vagrant-ubuntu-trusty-64.(none)')
【问题讨论】:
-
这在前面的Setting up Git中有介绍