git添加新用户

更改key的权限

chmod 600 /path/to/key
chmod 400 /path/to/key

添加key

eval "$(ssh-agent -s)"
ssh-add /path/to/key

configure user

git config user.name "yourname"
git config user.email "youremail"

原文地址:https://www.cnblogs.com/huangdong2000/p/12175948.html