- 强制覆盖本地代码
git fetch --all
git reset --hard origin/master
git pull
- 保存账号和密码
git config --global credential.helper store
- 修改远程地址
git remote set-url origin https://gitee.com/xx/xx.git (新地址)
git fetch --all
git reset --hard origin/master
git pull
git config --global credential.helper store
git remote set-url origin https://gitee.com/xx/xx.git (新地址)