用户名和邮箱地址相当于你的身份标识,是本地Git客户端的一个变量,不会随着Git库而改变。
每次commit都会用用户名和邮箱纪录。
- 查看用户名以及邮箱:
$ git config user.name
$ git config user.email
- 设置/更改用户名和邮箱,有先后顺序:
$ git config --global user.name "your name"
$ git config --global user.email "your email"
用户名和邮箱地址相当于你的身份标识,是本地Git客户端的一个变量,不会随着Git库而改变。
每次commit都会用用户名和邮箱纪录。
$ git config user.name
$ git config user.email
$ git config --global user.name "your name"
$ git config --global user.email "your email"