I'm trying to squash a range of commits - HEAD to HEAD~3. Is there a quick way to do this, or do I need to use rebase --interactive?
Make sure your working tree is clean, then
git reset --soft HEAD~3 git commit -m 'new commit message'
2.1m questions
2.1m answers
60 comments
57.0k users