Created
January 20, 2015 19:35
-
-
Save gpassarelli/2662fdc3ee15b35558a1 to your computer and use it in GitHub Desktop.
Ignoring “Your local changes to the following files would be overwritten by merge” on pull
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Git - force a pull to overwrite everything, on every pull | |
git fetch origin master | |
git reset --hard FETCH_HEAD | |
git clean -df |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#If you want remove all local changes from your working copy, simply stash them: | |
git stash save --keep-index; | |
#If you don't need them anymore, you now can drop that stash: | |
git stash drop; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment