[F007] Update

This functionality aims to surround : hg update and to adapt it for <ant> tags.

Shell command

hg update [-c] [-C] [-d DATE] [[-r] REV]

aliases: up, checkout, co

update working directory

    Update the repository's working directory to the specified changeset.

    If no changeset is specified, attempt to update to the head of the current
    branch. If this head is a descendant of the working directory's parent,
    update to it, otherwise abort.

    The following rules apply when the working directory contains uncommitted

    1. If neither -c/--check nor -C/--clean is specified, and if the requested
       changeset is an ancestor or descendant of the working directory's
       parent, the uncommitted changes are merged into the requested changeset
       and the merged result is left uncommitted. If the requested changeset
       is not an ancestor or descendant (that is, it is on another branch),
       the update is aborted and the uncommitted changes are preserved.
    2. With the -c/--check option, the update is aborted and the uncommitted
       changes are preserved.
    3. With the -C/--clean option, uncommitted changes are discarded and the
       working directory is updated to the requested changeset.

    Use null as the changeset to remove the working directory (like 'hg clone

    If you want to update just one file to an older changeset, use 'hg

    See 'hg help dates' for a list of formats valid for -d/--date.


 -C --clean  discard uncommitted changes (no backup)
 -c --check  check for uncommitted changes
 -d --date   tipmost revision matching date
 -r --rev    revision

use "hg -v help update" to show global options


Attribute Description Value Required
cmd hg command update yes
dir directory to update yes
clean overwrite locally modified files (no backup) true/false, yes/no, on/off no
date tipmost revision matching date no
revision revision no
check check for uncommitted changes true/false, yes/no, on/off no
Nested element Description Required
dirset resource collections no
arg command line argument value no


                    <hg cmd="update" dir="/my/rootdirectory/dir/to/update" revision="1"/>