记录下避免每次都需要输入git 账密的方法。
-
设置记住密码十五分钟:
git config --global credential.helper cache
-
如果你想自定义记住的时间,可以这样:
git config credential.helper 'cache --timeout=3600' //这里记住的是一个小时,如需其他时间,请修改3600为你想修改的时间,单位是秒
-
你也可以设置长期记住密码:
git config --global credential.helper store