Thread (3 messages) flat view 3 messages, 3 authors, 2016-06-15

Re: Prompt for merge message?

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:52:12

"Todd A. Jacobs" [off-list ref] writes:
I often find myself using "--no-ff -m foo" for merging short-lived
branches, because the merge commit usually needs to say something
about having finished a feature rather than referring to a branch that
will be deleted shortly anyway....
... Is there currently a way to get git to prompt for the merge message,
rather than using the default or requiring the -m flag? If not, isn't
this a common-enough use case to have that ability added to the merge
function?
Others commented on the current practices and gave their own useful tips
already, but an additional hint is to name your branch more sensibly, so
that you do not feel it is useless to record it in the history.

As to a real longer-term solution, I wouldn't mind a patch that teaches
"git merge" an "-e" option just like "git commit" has.

    $ git commit -m "Finish frotz feature" -e -a
    ... editor opens with the first line filled already here ...

is something I find myself using fairly often.

Thanks.

[offtopic: It is annoying that my MUA warns me

    "nospam+listmail@domain" may be bogus; do you really want to send?

Could you do something about it please?]
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help