当前位置:   article > 正文

git 设置全局账号密码_git全局设置用户名密码

git全局设置用户名密码

设置全局仓库的用户名密码

git config --global user.name "userName"  //你的用户名
git config --global user.email "email address" //你的邮箱地址
git config --list   //查看git设置情况
  • 1
  • 2
  • 3

git记住用户名以及密码

git config --global credential.helper store
  • 1

以上是全局,会在用户的主目录生成.gitconfig文件

cat .gitconfig 
[user]
        name = deploy@123.com
[credential]
        helper = store
  • 1
  • 2
  • 3
  • 4
  • 5

之后在主目录,操作git pull,会提示输入账号密码,需要输一次后面不需要在输

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/小惠珠哦/article/detail/897467
推荐阅读
相关标签
  

闽ICP备14008679号