Created
January 29, 2013 08:21
-
-
Save jclosure/4662652 to your computer and use it in GitHub Desktop.
Revert source in git repo
This file contains 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
Setting your branch to exactly match the remote branch can be done in two steps: | |
git fetch origin | |
git reset --hard origin/master | |
If you want to save your current branch's state before doing this (just in case), you can do: | |
git commit -a -m "Saving my work, just in case" | |
git branch my-saved-work | |
Now your work is saved on the branch "my-saved-work" in case you decide you want it back (or want to look at it later or diff it against your updated branch). |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment