(TIL) Git: Resetting A Reset
Sometimes we run commands like git reset --hard HEAD~ when we shouldn’t have. We wish we could undo what we’ve done, but the commit we’ve reset is gone forev...
Sometimes we run commands like git reset --hard HEAD~ when we shouldn’t have. We wish we could undo what we’ve done, but the commit we’ve reset is gone forev...
If you have lost track of a recent commit (perhaps you did a reset), you can generally still get it back. Run git reflog and look through the output to see i...
Generally when referencing a commit, you’ll use the SHA or a portion of the SHA. For example with git-show:
When working on a branch with multiple commits, you can “go back in time” and revise previous commits any way you please.
In my never-ending quest to better summarize my work at the end of the day using computers, I discovered today the Git --author flag. It works like this: