HIGH: Allow choosing email while queueing up PR to merge #64785
Unanswered
purajit
asked this question in
Pull Requests
Replies: 2 comments 1 reply
This comment has been minimized.
This comment has been minimized.
-
A solution similar to the per-organization notification routing would be preferred! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
IMO this is quite critical.
Situation
Currently, we have some cases where the commit author email is being overwritten with the account email during merge - meaning, when people set their
.gitconfig
locally to a specific email, the PR commit contains the correct email, but then the final commit pushed to the branch is associated with a different one when using a merge queue.After some testing, I found out that this is because the user likely in the past made a GitHub UI action on that repo using that other email, and now
gh pr merge
or clicking the Big Green Button uses that email for all operations.This also means that https://docs.github.com/en/github-ae@latest/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/setting-your-commit-email-address is an incorrect document, since setting your gitconfig is not guaranteed to be enough, and GitHub can decide not to honor this setting.
Another odd concern here is that the author email gets overwritten with
viewerDefaultCommitEmail
even for CLI-triggered merges, which IMO is unexpected, since it's meant for UI operations only.Problem
There seems to be no way to change the email used on that repo - without a merge queue, you get the option of choosing which email to use. With merge queue, there is no such drop down. I understand that I can probably ask the user to create a PR from the UI and use that do reassociate the repo with the correct email, but that seems like a very awkward workaround, and a very awkward thing to ask a user to do on every repo they have this problem with.
Possible solutions
I understand the latter suggestions are much bigger considerations, but I at least hope that adding the dropdown like in https://github.blog/changelog/2022-09-15-git-commit-author-shown-when-squash-merging-a-pull-request would be reasonable to accomplish rather soon.
Without this, we are unable to enforce repo rules that restrict commit author emails.
Beta Was this translation helpful? Give feedback.
All reactions