Git · Middle · Question 12 of 75
What does a squash merge of a pull request do?
- 1Rebases the PR and keeps each commit separately
- ✓Correct answer: Combines the PR's commits into one commit on the target
- 3Merges the PR with a merge commit and keeps all commits
Explanation
The target gets a single tidy commit, and the branch's intermediate commits aren't in its history. Downsides: big PRs become one huge commit, and the branch looks unmerged to Git.