您的位置:首页 > 其它

git push时总提示输入用户名和密码

2016-09-10 15:37 375 查看
我用的是Windows7系统.

C:\Users\yourUserName
下创建文件
.git-credentials
, 并在其中写入以下内容:
https://username:password@github.com
,

比如
https://john:mypassword@github.com


保存.

GitBash执行
git config --global credential.helper store


然后可以在当前目录中的
.gitconfig
文件中看到如下内容:

[credential]
helper = store
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  git