I’d like to merge my
feature-branch into my
develop-branch, but squash some commits into 1, while pulling in others as-is.
Is there a possibilty to
git merge --squash feature and then to choose which commits from the
feature-branch should be squashed and which taken as-is?
- Non-interactive fixup until specified hash
- How to squash commits in branches
- Is there a way to squash a number of commits non-interactively?
- How to squash the old commit and a recent merge commit
- How do I make a copy of a branch for testing rebase?
- How can I safely use git rebase when working on multiple computers?
One Solution collect form web for “Partial squash-merge”
Nah. You must use interactive rebase in order to do pick, delete, squash etc.
git rebase -i HEAD~4
Will let you decide on the four last commits.