How to Checkout the Previous Branch in Git
Sometimes, I forget the last branch name with how many branches I jump between.
Here's a simple way to switch to your previous branch in Git.
git checkout -
Or another way:
git checkout @{-1}
This second one is handy because you can use it to checkout N-th last branch/commit. So if you wanted to checkout 3 branches ago you could use:
git checkout @{-3}
I use the second way mostly because I find the @{-N}
very useful (and it's a built-in reflex of mine now).