Skip to content

Instantly share code, notes, and snippets.

@damianpumar
Last active June 8, 2024 14:51
Show Gist options
  • Save damianpumar/d0c6b886e2dad730f159f6229e33a123 to your computer and use it in GitHub Desktop.
Save damianpumar/d0c6b886e2dad730f159f6229e33a123 to your computer and use it in GitHub Desktop.
Clear all commits into one
HASH=$(git commit-tree HEAD^{tree} -m "🚀 First commit")
git reset $HASH
echo "🚀 First commit has been cleared"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment