How to change the default "Squash & Merge" commit message?

Adding another vote for this – we have a beautiful PR description that is approved, and then if the developer does not remember to copy that into the commit message when squash-and-merging, all we get on the master branch is a bulleted list of the original branch commits.

5 Likes

+1. It would be incredibly useful to set the default squash + merge commit message to the PR summary.

+1
Absolutely! This would be a super convenient alternative to always manually squashing, and pushing it.

It’s strange it’s not done yet because it seems not too difficult to implement and even Bitbucket has this feature for years

Please add this feature. Github PR Descriptions are usually very well written and very informative. It’s very nice if the title + PR link + description can just be in the squash commit message.

Voting for this as well! Many junior folks on my team often don’t look critically what’s in their commit message, but we have them writing good PR messages. Help us help ourselves!

1 Like

I would like to also add my voice here in support of this requested feature.

1 Like

+1
Would love to have the possibility to set default commit messages!

+1, PLEASE add an option to generate the squashed PR default commit message to use the PR’s description OR an option to leave it empty, forcing the developer to provide a good summary.

Yup, +1, plz and thank you

+1 Our team would also love for this to be configurable or at very least standard in always using the title

+1 For our team, the PR title is usually much more descriptive than the commit messages.

The reason why we chose squash is because we don’t care about the commit messages. Its strange to see that GitHub tries to preserve them and discard the perfectly good PR description.

I want squash to grab the PR title and PR description. This is especially important for the new “auto-merge” feature because the description might change.

Imagine this scenario:

  1. Dev creates PR with title/description and sets to automerge
  2. Reviewer leaves comments/suggestions
  3. Dev changes code to apply suggestions, also updates corresponding PR description to match the behavior of the code
  4. Reviewer approves, PR automatically merges

If the PR title/description were applied, all would be well. But the automerge feature requires assigning the merged title/description so the dev would have to turn off automerge, update PR desc, update squash description, turn on automerge again.

Please! It’s very frustrating to fix the Pull Request title only to have it ignored when merging just because there’s only a single commit.

This feature is due a long time ago. The implementation could be similar to the way you can add a default template for pull request descriptions.