[pre-push hook seems buggy] (was: "Push creates new remote heads" and my humble workflow (kind of dummy question))

Uwe Brauer oub at mat.ucm.es
Sun Jul 19 07:11:06 UTC 2020


   > On 7/16/20 11:28 AM, Victor Sudakov wrote:

   > You can make sure you alway pull before committing by adding a hook in
   > your config.


   > [hooks]
   > pre-commit=hg pull -u


Thanks for pointing this out. I found this hook a bit too confusing so I
tried out
pre-push:

pre-push=hg pull -u

Works as expected

But 


pre-push=hg fetch

Gave me

abort: working directory not at branch tip
(use 'hg update' to check out branch tip)
abort: pre-push hook exited with status 255


Which was nonsense. Just in case I run hg update 
but received the same message.

Is this a BUG?

Regards

Uwe Brauer
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5673 bytes
Desc: not available
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20200719/88744cfc/attachment.p7s>


More information about the Mercurial mailing list