How to add signoffs (Signed-Off-By: ...) ?

Peter Arrenbrecht peter.arrenbrecht at gmail.com
Sat Jun 28 00:32:52 CDT 2008


On Sat, Jun 28, 2008 at 12:29 AM, Gregory Collins <greg at maptuit.com> wrote:
> Kirill Smelkov <kirr at landau.phys.spbu.ru> writes:
>
>> Good evening,
>>
>> I'd like to ask a question about how to add signoffs like people do in
>> Linux kernel.
>>
>>
>> My workflow is something like this:
>>
>> When someone sends a patch series to our -patches list, I'd like to
>> import it into staging tree and add my "Signed-Off-By: me", or
>> "Reviewed-By: me".
>>
>> The problem is that to my knowledge and understanding of mercurial
>> codebase this is not possible with e.g.  commit/precommit/pretxncommit
>> hooks.
>
> You'll probably need to rewrite the changeset message to
> accomplish. Take a look at the mercurial queues extension; to add your
> signoff message you could do:
>
> $ hg qimport foo.diff
>
> # push patch onto queue
> $ hg qpush
>
> # modify changeset message here
> $ hg qrefresh -e
>
> # turn it into a "normal" changeset, i.e. import it into tree
> $ hg qdelete foo.diff

I think this should rather be

$ hg qdelete -r tip

Note that to add your signoff message, you could also edit the patch
directly (at least if it's in git format), either before or after
qimport, but certainly before qpush. This might be easier to automate.

-parren


More information about the Mercurial mailing list