0

I know how to include Mercurial hooks in my local repository. This is done by adding the hook to the hgrc file along with the location of the Python code and the Python hook.

[hooks] pretxncommit.require_case=python:.hg/require_case.py:require_case

Now I would like to take this hook and add it to the hgrc file located in the central repository. After I do make changes to the hgrc file of the central repository and when I do a mercurial clone on that repository, the hgrc file does not have my hook definition. This central repository is running under a Linux environment.

Am I missing anything in the steps. Any advice is appreciated. Thanks.

VRA
  • 11
  • 3

1 Answers1

0

The hook entries don't transfer between repositories, none of the details in hgrc do. See http://www.selenic.com/mercurial/hgrc.5.html under "Files"

<repo>/.hg/hgrc

Per-repository configuration options that only apply in a particular repository. This file is not version-controlled, and will not get transferred during a "clone" operation. Options in this file override options in all other configuration files. On Plan 9 and Unix, most of this file will be ignored if it doesn't belong to a trusted user or to a trusted group. See the documentation for the [trusted] section below for more details.

Truan
  • 379
  • 2
  • 10