You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Use the local author name and e-mail address for merging #5892
When merging a pull request via gh pr merge --merge, the generated merge commit uses the e-mail address configured as the primary e-mail of the respective GitHub account. This may not be what the user wants. For example, if a user (like me) uses different e-mail addresses for business and private repositories, it becomes necessary to change the primary e-mail address setting of the GitHub account when switching between business and private work. This is not only cumbersome, but also makes it very easy to accidentally produce commits with the wrong e-mail address.
Proposed solution
I propose that gh pr merge uses the e-mail address and, for the sake of consistency, also the author’s name that are configured locally. This way, gh pr merge would produce merge commits with the same author information as git commit. An even better solution might be to make the author name and e-mail address configurable via an option to gh pr merge and use the data that git commit would use as the default.
@jeltsch Appreciate the detailed issue, we have an open issue for this feature #1450 and seems like there is already a PR addressing it it, so hopefully it will be in soon.
Activity
samcoe commentedon Jul 11, 2022
@jeltsch Appreciate the detailed issue, we have an open issue for this feature #1450 and seems like there is already a PR addressing it it, so hopefully it will be in soon.