Git|Git Tips

1、有些FQ需要设置代理 【Git|Git Tips】设置你自己的IP和host

git config --global http.proxy 'socks5://127.0.0.1:1080' git config --global https.proxy 'socks5://127.0.0.1:1080'

使用git config --global --list命令查看是否配置成功
移除git代理配置,可以用下面命令
git config --global --unset http.proxy git config --global --unset https.proxy

2、.gitignore 不起作用问题的解决
git rm -r --cached . git add . git commit -m "update gitignore"

3、解决Mac下SourceTree每次都让输入密码的问题 1、命令行进入项目目录,输入:
git config --global credential.helper store
2、在source tree更新代码,提示输入密码,输入一次后以后就不需要输入了

    推荐阅读