打开本地的.git/config
加入
[credential] helper = store
保存,第一次需要输入用户名密码,输入一次密码后第二次就会记住密码了不会再提示输入用户名及密码
git 保存用户名密码
原文:http://www.cnblogs.com/lixiaolun/p/7028681.html