Back

Explore Courses Blog Tutorials Interview Questions
0 votes
1 view
in DevOps and Agile by (19.4k points)
edited by

How can I squash my last X commits together into one commit using Git?

1 Answer

0 votes
by (27.5k points)

Use the following commands to squash last n commits into single commit

 git reset -- soft HEAD~n &&
 git commit

Related questions

Welcome to Intellipaat Community. Get your technical queries answered by top developers!

28.4k questions

29.7k answers

500 comments

94.2k users

Browse Categories

...