配置用户名和邮箱:

git config --global user.name 'pzdn2009'
git config --global user.email 1050244110@qq.com

如上命令,如果要配置当前repository的user信息,则可以去掉global选项。

其他有用的配置:

gig config --global core.editor emacs #配置文本工具
git config --global merge.tool vimdiff #配置合并工具
git config --global diff.tool vsdiffmerge  #配置差异工具

查看配置的选项

git config --list
cat ~/.gitconfig

2. help

一下三种形式均可:

git help <verb>
git <verb> --help
man git-<verb>

相关文章:

  • 2021-04-29
  • 2021-07-05
  • 2021-08-29
  • 2021-05-22
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-09-20
  • 2022-12-23
  • 2022-02-21
  • 2021-06-17
  • 2021-08-17
  • 2021-08-29
相关资源
相似解决方案