pwntester / octo.nvim

Edit and review GitHub issues and pull requests from the comfort of your favorite editor
MIT License
2.33k stars 125 forks source link

Allow editing commit message for squash merge #266

Open mrswats opened 2 years ago

mrswats commented 2 years ago

Allow Editing Commit message for squash merge

In the GitHub UI you are allowed to modify the commit message before you merge squash a pull request. This capability was added in the CLI: https://github.com/cli/cli/issues/1023, but I couldn't find the option to do this in Octo.

Describe what happened (or what feature you want)

I would like to be able to edit the commit message before merging.

Original question: https://github.com/pwntester/octo.nvim/discussions/264

pwntester commented 2 years ago

Hi! Can you describe the workflow you would like to be implemented? 1) Octo pr merge squash body (adding a body flag), a popup opens and when the window closed, the text is used for the gh --body parameter 2) Octo pr merge_edit squash (using a different action). Similar behaviour (popup -> --body)

Im leaning for the second one. Any preferences?

mrswats commented 2 years ago

If possible I would love for a buffer with the default text to appear always and then that text is used for the commit message. This way, we can pass a flag to act as --fill or something along these lines.

vitorf7 commented 10 months ago

@pwntester I would probably lean towards the first one. We could however as @mrswats was saying maybe by default (or based on a configuration option) open a pop to change the commit message. We could also add the body flag as a way to get that pop up (if people have the auto change config opt turned off).