-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Provide more context when creating a Pull Request #997
Comments
#1221 adds an enhancement to pre-fill the title and body when there is only one commit, but we would really like to make this a better, more fleshed out experience! ProblemOverviewDepending on where you are in development (and your workflow), PRs might often contain way more than one commit. Some of these commits contain meaningful information about the intentions of the changes, while other commits might just be "Fix typo". All this information is hard to retrieve when creating a PR, as it isn't accessible on the same screen as the PR Creation form, or if it is it isn't easily accessible. User Impact
Solution 1Use the same strategy that git uses when squashing commits and pre-fill the PR body field with all the commit messages. The user can then manually edit the title and body as normal. Potential problems, limitations, challenges
Solution 2Provide a list of all the commits on the branch on the same area as the PR creation form. Allow the user to select one of the commits to use as the title of the PR. Allow the user to select x commits for the body of the PR field, and copy over that information into the PR body field. The user can manually edit the title and body. Potential problems, limitations, challenges
|
@donokuda ☝️ UI challenge for you here, what do you think? |
Solution number 2 seems to make the most sense here. Couple of clarifying questions and thoughts:
I'm a little curious on how often a branch will contain a commit that summarizes an entire feature. I would argue that we won't need to worry about the title at the moment. Instead, we have the description guide the author on what the title should be. There's one last thing I'd also like to focus on as an additional solution: Changed Files (and diffs!)OverviewIn addition to commits, the files that have been touched in a branch help tell the story of what types of changes are expected to go into the target branch. It also helps the author verify that there aren't any unintentional changes sneaking in. User impact
Solution: Show a list of files that have changedBy listing out the files that have changed, an author can glance and verify that these are changes that are meant to go into the pull request. Seeing what files have changed could also help infer what to write in the pull request description. Potential problems, limitations, challenges
Solution: Allow viewing the diff between branchesBeing able to view the diff between branches would help understand the changes being brought in as a whole and how multiple commits come together. Ideally, it should be quick to view changes for each file given that changes in one file might be related to changes in another file. Potential problems, limitations, challenges
|
When I go to create a Pull Request from within the GitHub extension, it would be helpful to have more context readily displayed to help me craft a PR message.
One thing that Desktop does that I like is if there is only one commit in the branch (as compared to the target), it'll pre-fill the form with that commit title and message. It's a nice touch.
But most of the time, I have many commits. It'd be nice to maybe see the last few commits below and a quick way to see the changes. Just enough to jog my memory and help me describe the PR.
The text was updated successfully, but these errors were encountered: