# Interactive — let you pick which commits to squash and write a fresh message
git rebase -i HEAD~5
# Non-interactive: reset to N commits back, leaving changes staged,
# then commit with a clean message
git reset --soft HEAD~5
git commit -m "feat: complete user onboarding flow"
# Force-push to update the remote branch (only for YOUR feature branch — never main)
git push --force-with-lease # safer than --force, refuses if remote moved
Create a free account and build your private vault. Share publicly whenever you want.