How to get path to repository for a global hook

Jerry Maloney gerard.maloney at mmodal.com
Thu Apr 11 01:27:29 UTC 2013


I am writing a global hook to run on our SCM server that sets file permissions appropriately whenever incoming changesets are applied. So something like this in /etc/mercurial/hgrc:

[hooks]
changegroup.permissions = chmod -R u+x /path/to/the/directory/being/updated

But I can't figure out how to get a real value for /path/to/the/directory/being/updated. I figured there would be something available in templates, but I can't see it.

I could write a hook for each repository, but we have a lot of them and the list is always growing, so I would prefer not to do this.

Thanks,
-- Jerry

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20130411/cea5d32e/attachment-0002.html>


More information about the Mercurial mailing list