Code Tools: trees

The trees Mercurial extension helps manage loosely-coupled nested repositories (aka 'trees').

A 'tree' is simply a repository that may contain other repositories (or other trees) nested within its working directory. This extension provides commands that operate on an entire tree, or on selected trees within it. For example, the command hg tpull will pull changes into each repo in a tree.

The trees extension will soon be enabled on the OpenJDK Mercurial server; to enable it for your copy of Mercurial:

  1. Download trees.py and save it somewhere convenient. (Alternatively, you can clone the trees respository.)
  2. Add a line to the [extensions] section of your ~/.hgrc file:

    trees = <path_to_your_copy>/trees.py

Mercurial compatibility

Mercurial version 1.6 or later is required for complete functionality, although most features work with versions 1.1 and later. Versions prior to 1.1 are not supported. The extension uses 'pushkey' support, added in Mercurial 1.6, to automatically discover the subtree configuration of a remote repository (i.e., one accessed via http or ssh). It also uses utility methods added in 1.6 to properly split quoted configuration items.

Thus when used with Mercurial versions 1.1 - 1.5.4, the following features are not available:

Examples

Further information