Git强制覆盖本地代码

git 强制覆盖

git fetch --all
git reset --hard origin/master
git pull

单条执行

  • git fetch –all && git reset –hard origin/master && git pull