From 0da7d0800fe089d24898bc7b96302475c16f3c31 Mon Sep 17 00:00:00 2001 From: Jason Fleetwood-Boldt Date: Thu, 31 Aug 2023 14:17:48 -0400 Subject: [PATCH 1/2] Update configuring-commit-squashing-for-pull-requests.md clarifies how to find the "Pull requests" section (it's on the General tab but you have to scroll down to see it) --- .../configuring-commit-squashing-for-pull-requests.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/content/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/configuring-commit-squashing-for-pull-requests.md b/content/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/configuring-commit-squashing-for-pull-requests.md index dcc83e6b8bd4..4a2c008e45d9 100644 --- a/content/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/configuring-commit-squashing-for-pull-requests.md +++ b/content/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/configuring-commit-squashing-for-pull-requests.md @@ -20,9 +20,14 @@ shortTitle: Configure commit squashing {% data reusables.repositories.navigate-to-repo %} {% data reusables.repositories.sidebar-settings %} -1. Under "Pull Requests", select **Allow squash merging**. This allows contributors to merge a pull request by squashing all commits into a single commit. The default commit message presented to contributors when merging is the commit title and message if the pull request contains only 1 commit, or the pull request title and list of commits if the pull request contains 2 or more commits. {% ifversion ghes = 3.6 %} To always use the title of the pull request regardless of the number of commits in the pull request select **Default to PR title for squash merge commits**.{% endif %} +1. On the "General" tab (which is selected by default), scroll down to the section marked "Pull Requests". +![Screenshot 2023-08-31 at 2 16 53 PM](https://github.com/github/docs/assets/59002/fc027e4c-62f5-4abd-8530-050fa24060a3) + + + + Select **Allow squash merging**. This allows contributors to merge a pull request by squashing all commits into a single commit. The default commit message presented to contributors when merging is the commit title and message if the pull request contains only 1 commit, or the pull request title and list of commits if the pull request contains 2 or more commits. {% ifversion ghes = 3.6 %} To always use the title of the pull request regardless of the number of commits in the pull request select **Default to PR title for squash merge commits**.{% endif %} {% ifversion default-merge-squash-commit-message %} -1. Optionally, under **Allow squash merging**, select the dropdown menu, then click the format of the default squash commit message presented to contributors when merging. + Optionally, under **Allow squash merging**, select the dropdown menu, then click the format of the default squash commit message presented to contributors when merging. The default message uses the commit title and message if the pull request contains only 1 commit, or the pull request title and list of commits if the pull request contains 2 or more commits. You can also choose to use just the pull request title, the pull request title and commit details, or the pull request title and description. {% endif %} From f9ba544d7f035db51c6b809666fa73c3bb8293c3 Mon Sep 17 00:00:00 2001 From: Anne-Marie <102995847+am-stead@users.noreply.github.com> Date: Thu, 7 Sep 2023 11:53:02 +0200 Subject: [PATCH 2/2] Apply suggestions from code review --- .../configuring-commit-squashing-for-pull-requests.md | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/content/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/configuring-commit-squashing-for-pull-requests.md b/content/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/configuring-commit-squashing-for-pull-requests.md index 4a2c008e45d9..0eecc2a3cfa4 100644 --- a/content/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/configuring-commit-squashing-for-pull-requests.md +++ b/content/repositories/configuring-branches-and-merges-in-your-repository/configuring-pull-request-merges/configuring-commit-squashing-for-pull-requests.md @@ -20,14 +20,10 @@ shortTitle: Configure commit squashing {% data reusables.repositories.navigate-to-repo %} {% data reusables.repositories.sidebar-settings %} -1. On the "General" tab (which is selected by default), scroll down to the section marked "Pull Requests". -![Screenshot 2023-08-31 at 2 16 53 PM](https://github.com/github/docs/assets/59002/fc027e4c-62f5-4abd-8530-050fa24060a3) - - - - Select **Allow squash merging**. This allows contributors to merge a pull request by squashing all commits into a single commit. The default commit message presented to contributors when merging is the commit title and message if the pull request contains only 1 commit, or the pull request title and list of commits if the pull request contains 2 or more commits. {% ifversion ghes = 3.6 %} To always use the title of the pull request regardless of the number of commits in the pull request select **Default to PR title for squash merge commits**.{% endif %} +1. On the "General" settings page (which is selected by default), scroll down to the section marked "Pull Requests". +1. Under "Pull Requests", select **Allow squash merging**. This allows contributors to merge a pull request by squashing all commits into a single commit. The default commit message presented to contributors when merging is the commit title and message if the pull request contains only 1 commit, or the pull request title and list of commits if the pull request contains 2 or more commits. {% ifversion ghes = 3.6 %} To always use the title of the pull request regardless of the number of commits in the pull request select **Default to PR title for squash merge commits**.{% endif %} {% ifversion default-merge-squash-commit-message %} - Optionally, under **Allow squash merging**, select the dropdown menu, then click the format of the default squash commit message presented to contributors when merging. +1. Optionally, under **Allow squash merging**, select the dropdown menu, then click the format of the default squash commit message presented to contributors when merging. The default message uses the commit title and message if the pull request contains only 1 commit, or the pull request title and list of commits if the pull request contains 2 or more commits. You can also choose to use just the pull request title, the pull request title and commit details, or the pull request title and description. {% endif %}