Git Cheatsheet

Written
  • git rev-parse --show-toplevel prints out the root directory of the repo
  • git restore -p <file> can restore chunks selectively and will ask you whether or not to revert each chunk.

Thanks for reading! If you have any questions or comments, please send me a note on Twitter. And if you enjoyed this, I also have a newsletter where I send out interesting things I read and the occasional nature photo.

You can check out a recent issue, or enter your email below to subscribe.