Squashing a Git commit


/ Published in: Bash
Save to your folder(s)

Squashing
---------
WARNING: "git rebase" changes history. Be careful. Google it.

git rebase --interactive HEAD~10
(then change all but the first "pick" to "squash")
squash the last 10 commits into one big commit


Copy this code and paste it in your HTML
  1. git rebase --interactive HEAD~10

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.