git how to overwrite local changes with remote code example Example: git overwrite local changes git fetch --all git reset --hard origin/master