git reflog + git reset
logs all actions you made:
git reflog show master
reset to some reflog:
git reset --hard master@{x}
Written by Felipe Elias Philipp
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Git
Authors

filipekiss
702.8K

khasinski
595.9K
Related Tags
#git
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#