首先打开config文件:
$ git config --global --edit
GNU nano 2.5.3 File: /home/vagrant/.gitconfig
This is Git’s per-user configuration file. [user]
Please adapt and uncomment the following lines:name = Eagle
email = 492617424@qq.com
Ctrl + X保存退出后,运行
$ git commit --amend --reset-author
好了,这样就完成了!