


This is due to TortoiseHg using its own python system and not finding llbase. (to skip this check, commit a trivial change to this file,Īnd add the text "'warn-on-failure:valid-llsd'" to your commit comment) If you use TortoiseHg and find errors such as this:Ĭhecking Linden Lab proprietary coding policies.Īutobuild.xml: this hook requires llsd from the llbase python package nfirm = python:/path/to/confirm_target.py:hook To install, add the following to your Mercurial Initialization File (changing /path/to to the location where you checked out the hg-tools repository): It will prompt you for confirmation if you attempt to push into any repository whose name ends with one of: The confirm_target.py hook can be used to protect yourself from accidentally pushing to sensitive repositories.

f|-file FILE a file to check (whether or not it has been modified) r|-rev REVISION a revision up to which you would like to check (may be specified more than once for a range) Options: -p|-policy POLICY The set of policies to check: POLICY may be either 'opensource' or 'proprietary' (the default depends on the repository) The checks may be against either of two policy sets: opensource or proprietary The pretxnchangegroup hook will then analyze all the pulled changes. Make a clone of the destination repository.
#Where does mercurial for mac install install#
Install the pretxnchangegroup hook as described above.I am working on it, but the hook function, checking changes in your local repository prior to commit, and checking a specific file do seem to be working.Īs an alternative to the above - if you need to see whether or not the changes in your repo will pass the commit hook when pulled to some other repo, preview the operation by: Warning: Specifying another repository currently does not work. To check changes that would be pushed by default, specify "default-push" as the repository name. When given a remote repository, check changes that have been committed locally that are not present in the remote repository. When revisions are specified via -r/-rev, check the given committed changes in the local repository. With no arguments, check uncommitted changes in the working directory.Ī specific file (whether or not it has been added to the repository or modified) can be checked by using the -f/-file file option. To check changes against Linden Lab coding policy To install the extension, add the following to your Mercurial Initialization File (changing /path/to to the location where you checked out the hg-tools repository): You can exempt a specific repository by adding an empty hook assignment to it this is useful for working on older repositories that don't contain all the fixes to make them pass: Operations on those repositories will print a message describing which policy is being applied, or one that indicates that the repository is not subject to Linden Lab policy checks. These hooks apply only to repositories that are related to (share a common ancestor with) specific Linden Lab repositories (see the repo_root variable assignment in the source). ding_policy = python: /path/to/coding_policy.py:hookĪnyone maintaining a shared repository is encouraged to install this so that you can prevent problems when you attempt to merge your shared repository back to viewer-development.

You can also check all changes you pull into your repository by adding this (also under ): ding_policy = python: /path/to/coding_policy.py:hook To make that check automatic when you are doing local commits, add the following to your Mercurial Initialization File (changing /path/to to the location where you checked out the hg-tools repository): This is enforced when the changes are pulled by the hook provided by coding_policy.py. The coding_policy.py file provides both a Mercurial command extension hg policy and a hook that you should install to check all files when they are committed.Īll changes pulled to a Linden Lab repository will have to pass the checks enforced by the command above. If the file does not exist, create it (see Creating a version control repository#Preparing_to_use_Mercurial). You should have created this file when you installed Mercurial and established your username (and, optionally, your email address).
