• P
    am: let --signoff override --no-signoff · b5e82359
    Paul Tan 提交于
    After resolving a conflicting patch, a user may wish to sign off the
    patch to declare that the patch has been modified. As such, the user
    will expect that running "git am --signoff --continue" will append the
    signoff to the commit message.
    
    However, the --signoff option is only taken into account during the
    mail-parsing stage. If the --signoff option is set, then the signoff
    will be appended to the commit message. Since the mail-parsing stage
    comes before the patch application stage, the --signoff option, if
    provided on the command-line when resuming, will have no effect at all.
    
    We cannot move the append_signoff() call to the patch application stage
    as the applypatch-msg hook and interactive mode, which run before patch
    application, may expect the signoff to be there.
    
    Fix this by taking note if the user explictly set the --signoff option
    on the command-line, and append the signoff to the commit message when
    resuming if so.
    Signed-off-by: NPaul Tan <pyokagan@gmail.com>
    Signed-off-by: NJunio C Hamano <gitster@pobox.com>
    b5e82359
am.c 58.1 KB