mercurialhgrc

Are hgrc files inside a mercurial repo tracked by the repo itself?


We have an hgrc file that contains settings that should be global to all members of our development team. When I make changes to my hgrc file I do not appear to be able to have these changes propagate to anybody else who clones a repo.

Is there a way to keep these configs global to any user of the repo?

Repo track thyself!


Solution

  • $REPO/.hg/hgrc is not tracked by Mercurial. This is by design for security reason.

    You can commit template and create project policy that require setting several setting to $REPO/.hg/hgrc or add to build scripts helper target to deploy template to $REPO/.hg.

    I recommend use precommit hooks on central server to ensue that all changes are good. Look to

    Note that some files Mercurial treated as special, for example $REPO/.hgignore or .hgeol for EOL plug-in. These files you can commit, so they are easy sharing in dev team.