[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10. Commands for Branching and Merging

10.1 tag  create a continuation revision (aka tag or branch)
10.2 update  update a project tree to reflect recent archived changes
10.3 replay  apply revision changesets to a project tree
10.4 star-merge  merge mutually merged branches
10.5 apply-delta  Compute a changeset between any two trees or revisions and apply it to a project tree
10.6 missing  print patches missing from a project tree
10.7 join-branch  construct a project tree for a version
10.8 sync-tree  unify a project tree's patch-log with a given revision
10.9 delta  Compute a changeset (or diff) between any two trees or revisions

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.1 tag

create a continuation revision (aka tag or branch)

usage: tla tag [options] SOURCE-REVISION TAG-VERSION

 
  -h, --help         Display a help message and exit.
  -H                 Display a verbose help message and exit.
  -V, --version      Display a release identifier string
                     and exit.
  -A, --archive      Override `my-default-archive'
  -l, --log FILE     commit with log file FILE
  --no-cacherev      Do not cacherev tag even if different archive
  --seal             create a version-0 revision
  --fix              create a versionfix revision
  -S, --setup        use `archive-setup' if necessary.

Create the continuation revision TAG-VERSION (branch point or tag) which is equivalent to SOURCE-REVISION (plus a log entry).

If no log entry is provided, a trivial log entry will be created.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.2 update

update a project tree to reflect recent archived changes

usage: tla update [options] [version/revision]

 
  -h, --help       Display a help message and exit.
  -H               Display a verbose help message and exit.
  -V, --version    Display a release identifier string
                   and exit.
  -A, --archive    Override `my-default-archive'
  -d, --dir DIR    Update project tree in DIR (default `.')
  -N, --forward    pass the --forward option to `patch'
  --dest DEST      Instead of modifying the project tree in-place,
                   make a copy of it to DEST and apply the result to that

Update a project tree by getting the latest revision of VERSION (or the default version of the project tree) and then applying a patch set of the differences between the project tree and the highest revision with which it is up-to-date.

If the merge involves conflicts, a warning message is printed, and the new project tree will contain ".rej" files.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.3 replay

apply revision changesets to a project tree

usage: tla replay [options] [version/revision...]

 
  -h, --help          Display a help message and exit.
  -H                  Display a verbose help message and exit.
  -V, --version       Display a release identifier string
                      and exit.
  -A, --archive       Override `my-default-archive'
  --list FILE         read a list of patches to apply
  --new               replay only new patches
  --reverse           reverse the named patch
  -N, --forward       pass the --forward option to `patch'
  -d, --dir DIR       Operate on project tree in DIR (default `.')
  --dest DEST         Instead of modifying the project tree in-place,
                      make a copy of it to DEST and apply the result to that
  --skip-present      skip patches that contain 1 or more patch logs already in this tree

The result is formed by applying patches in the latest revision of VERSION (or the default version of the project tree), stopping after the first patch that causes conflicts. If multiple VERSIONs are specified, they are applied in turn.

If one or more specific REVISIONs (including patch-levels) is specified instead, only those patch sets, and no others, will be applied.

With the --list option, read a list of patches to apply from FILE (- for standard input). Complete revision names should be listed, one per line. replay will stop at the first patch in the list that causes a merge conflict, leaving behind files with names of the form:

 
   ,,replay.conflicts-in --  the name of the patch that caused conflicts

 
   ,,replay.remaining    --  the list of patches not yet applied


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.4 star-merge

merge mutually merged branches

usage: tla star-merge [options] [FROM]

 
  -h, --help               Display a help message and exit.
  -H                       Display a verbose help message and exit.
  -V, --version            Display a release identifier string
                           and exit.
  -A, --archive            Override tree archive
  -c, --changes OUTPUT     Generate but don't apply the changeset.
  -r, --reference VERSION  Set reference version (default: project tree version)
  -N, --forward            pass the --forward option to `patch'
  -t, --three-way          Perform a 3-way (diff3-style) merge.
  -d, --dir DIR            Operate on project tree in DIR (default `.')

Merge changes from FROM into the project tree, considering common ancestry from the project tree reference version, REFERENCE (which defaults to the tree version of the project tree). If FROM is not given, it defaults to the tree revision.

The purpose of this command is to merge changes between development lines which may have merged in both directions. It uses merge history to attempt to minimize the spurious conflicts that can arise from `mutual merging'.

FROM indicates a revision (it may be specified as a version name, indicating the latest revision in that version).

TREE is the project tree into which the merge will occur.

Star-merge works by computing the most recent ANCESTOR revision of REFERENCE and FROM and then applying the changeset:

 
         delta (ANCESTOR, FROM)

to TREE.

The "most recent ancestor" is defined as follows:

MAYBE_ANCESTOR_1 is defined as the highest patch level of FROM in REFERENCE for which both TREE and FROM have a patch log. In other words, it is the latest REFERENCE revision of FROM's version already merged into TREE.

MAYBE_ANCESTOR_2 is defined as the highest patch level in REFERENCE for which both FROM and REFERENCE have a patch log. In other words, it is the latest revision of REFERENCE already merged into FROM.

MAYBE_ANCESTOR_2, if it is not "nil", was merged into FROM at some revision of FROM's version, which we can call LAST_MERGE_INTO_FROM.

If both MAYBE_ANCESTOR_1 or MAYBE_ANCESTOR_2 are nil, star-merge can do nothing.

If just one of MAYBE_ANCESTOR_1 is MAYBE_ANCESTOR_2 is not nil, then that non-nil value is ANCESTOR.

If both MAYBE_ANCESTOR_1 and MAYBE_ANCESTOR_2 are not nil, then LAST_MERGE_INTO_FROM and MAYBE_ANCESTOR_1 are compared (both are revisions in FROM's version). If MAYBE_ANCESTOR_1 is the later revision, then MAYBE_ANCESTOR_1 is ANCESTOR, otherwise, MAYBE_ANCESTOR_2 is ANCESTOR.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.5 apply-delta

Compute a changeset between any two trees or revisions and apply it to a project tree

usage: tla apply-delta [options] FROM(REVISION|DIR) TO(REVISION|DIR)

 
  -h, --help       Display a help message and exit.
  -H               Display a verbose help message and exit.
  -V, --version    Display a release identifier string
                   and exit.
  -A, --archive    Override `my-default-archive'
  -N, --forward    pass the --forward option to `patch'
  --cache DIR      specify a cache root for pristine copies
  -d, --dir DIR    Operate on project tree in DIR (default `.')
  --dest DEST      Instead of modifying the project tree in-place,
                   make a copy of it to DEST and apply the result to that

A delta between A and B (both of which may be either a full revision or a project tree) is computed, and then applied to the project tree.

Exit Status Codes:

 
    0  No conflict during patch
    1  Conflicts occurred during patch
    3  Internal Error


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.6 missing

print patches missing from a project tree

usage: tla missing [options] [revision]

 
  -h, --help          Display a help message and exit.
  -H                  Display a verbose help message and exit.
  -V, --version       Display a release identifier string
                      and exit.
  -A, --archive       Override `my-default-archive'
  -d, --dir DIR       cd to DIR first
  -r, --reverse       sort from newest to oldest
  -s, --summary       display a summary of each missing patch
  -c, --creator       display the creator of each missing patch
  -D, --date          display the date of each missing patch
  -f, --full          print full revision names
  --merges            print a merge list for each missing patch
  --skip-present      skip patches that contain 1 or more patch logs already in this tree

Print a list of patches missing in the project tree containing DIR (or the current directory) for VERSION (or the default version. of the project tree).

The flag --merges means, for each patch, to print the list of patches included in the patch in two columns. For example:

 
        PATCH-A        PATCH-A
        PATCH-A        PATCH-B
        PATCH-A        PATCH-C

means that PATCH-A includes the changes from PATCH-B and PATCH-C. (Every patch includes at least itself.)


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.7 join-branch

construct a project tree for a version

usage: tla join-branch [options] version

 
  -h, --help       Display a help message and exit.
  -H               Display a verbose help message and exit.
  -V, --version    Display a release identifier string
                   and exit.
  -A, --archive    Override `my-default-archive'
  -d, --dir DIR    Operate on project tree in DIR (default `.')
  --dest DEST      Instead of modifying the project tree in-place,
                   make a copy of it to DEST and apply the result to that

REVISION must be a continuation (e.g. tag) of an ancestor of the project tree. The command replays the changeset for REVISION in the project tree, which has the effect of adding the log for the branch (making the tag an ancestor of the resulting tree).

As an exception to the usual rules, REVISION may be abbreviated as a version name, in which case the base-0 revision of that version is indicated.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.8 sync-tree

unify a project tree's patch-log with a given revision

usage: tla sync-tree [options] revision

 
  -h, --help       Display a help message and exit.
  -H               Display a verbose help message and exit.
  -V, --version    Display a release identifier string
                   and exit.
  -A, --archive    Override `my-default-archive'
  -d, --dir DIR    Operate on project tree in DIR (default `.')
  --dest DEST      Instead of modifying the project tree in-place,
                   make a copy of it to DEST and apply the result to that

The new project tree is formed by getting the REVISION and adding all patch-log entries from REVISION. No actual merging is performed -- only the patch-log is changed.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

10.9 delta

Compute a changeset (or diff) between any two trees or revisions

usage: tla delta [options] (REVISION|TREE)-A (REVISION|TREE)-B [DESTDIR]

 
  -h, --help       Display a help message and exit.
  -H               Display a verbose help message and exit.
  -V, --version    Display a release identifier string
                   and exit.
  -A, --archive    Override `my-default-archive'
  --cache DIR      specify a cache root for pristine copies
  --diffs          print changeset report with diffs

Given (REVISION|TREE)-A and (REVISION|TREE)-B, tla will build a changeset that comprises the changes between REVISION-A and REVISION-B

Example:

 
  tla delta tla--devo--1.1--patch-6 \
            tla--devo--1.1--patch-8 ,,changes

 
  Will pull patch-6 and patch-8 from tla--devo--1.1 and compute
  a changeset, which will be saved in a newly created ,,changes
  directory. If you would like a report instead,
  append the --diffs option

[ << ] [ >> ]           [Top] [Contents] [Index] [ ? ]

This document was generated by wilk on May, 11 2004 using texi2html