Skip to content

Instantly share code, notes, and snippets.

@textarcana
Created November 21, 2024 17:29
Show Gist options
  • Save textarcana/492fcfb40e26f37ea47ffaa27f1eed60 to your computer and use it in GitHub Desktop.
Save textarcana/492fcfb40e26f37ea47ffaa27f1eed60 to your computer and use it in GitHub Desktop.
In git, put the repo into the state it was at commit X, without changing history. Like git stash pop but for git history.
git checkout <hash> -- .
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment