doc/hg.1.txt
author mpm@selenic.com
Fri, 24 Jun 2005 12:33:14 -0800
changeset 458 ff8fbf99cd64
parent 438 b38deaf7873e
child 478 f1804f2e7f35
child 484 934279f3ca53
permissions -rw-r--r--
Added tag 0.6 for changeset 12e0fdbc57a0be78f0e817fd1d170a3615cd35da
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
     1
HG(1)
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
     2
=====
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
     3
Matt Mackall <mpm@selenic.com>
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
     4
v0.6, 27 May 2005
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
     5
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
     6
NAME
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
     7
----
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
     8
hg - Mercurial source code management system
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
     9
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    10
SYNOPSIS
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    11
--------
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    12
'hg' [-v -d -q -y] <command> [command options] [files]
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    13
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    14
DESCRIPTION
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    15
-----------
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    16
The hg(1) command provides a command line interface to the Mercurial system.
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    17
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    18
OPTIONS
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    19
-------
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    20
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    21
--debug, -d::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    22
    enable debugging output
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    23
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    24
--quiet, -q::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    25
    suppress output
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    26
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    27
--verbose, -v::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    28
    enable additional output
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    29
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    30
--noninteractive, -y::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    31
    do not prompt, assume 'yes' for any required answers
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    32
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    33
COMMAND ELEMENTS
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    34
----------------
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    35
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    36
files ...::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    37
    indicates one or more filename or relative path filenames
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    38
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    39
path::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    40
    indicates a path on the local machine
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    41
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    42
revision:: 
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    43
    indicates a changeset which can be specified as a changeset revision
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    44
    number, a tag, or a unique substring of the changeset hash value
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    45
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    46
repository path::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    47
    is either the pathname of a local repository of the URI of a remote
181
038e4d8602bd updated for .hgpaths and http/old-http protocol name change
jake@edge2.net
parents: 177
diff changeset
    48
    repository.  There are two available URI protocols, http:// which is
038e4d8602bd updated for .hgpaths and http/old-http protocol name change
jake@edge2.net
parents: 177
diff changeset
    49
    fast and the old-http:// protocol which is much slower but does not 
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    50
    require a special server on the web host.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    51
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    52
COMMANDS
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    53
--------
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    54
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    55
add [files ...]::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    56
    Add the given files to the repository.  Note that this just schedules the
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    57
    files for addition at the next hg commit time.
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    58
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    59
addremove::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    60
    Add all new files and remove all missing files from the repository.  New
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    61
    files are ignored if they match any of the patterns in .hgignore
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    62
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    63
annotate [-r <rev> -u -n -c] [files ...]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    64
    List the files with each line showing the revision id responsible 
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    65
    for that line. 
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    66
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    67
    options:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    68
    -r, --revision <rev>  annotate the specified revision
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    69
    -u, --user            list the author
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    70
    -c, --changeset       list the changeset
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    71
    -n, --number          list the revision number (default)
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    72
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    73
cat <file> [revision]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    74
    Output the given revision or tip of the specified file to stdout.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    75
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    76
commit [-A -t -l <file> -t <text> -u <user> -d <datecode>] [files...]::
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    77
    commit all changed files in the working dir to the repository.  This uses
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    78
    the EDITOR environment variable to bring up an editor to add a commit
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    79
    comment.
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    80
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    81
    Options:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    82
    
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    83
    -A, --addremove       run addremove during commit
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    84
    -t, --text <text>     use <text> as commit message
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    85
    -l, --logfile <file>  read the commit message from the specified
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    86
                          file
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    87
    -d, --date <datecode> use the specified date code
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    88
    -u, --user <user>     record commit as the specified user
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    89
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    90
    aliases: ci
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    91
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    92
copy <source> <dest>::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    93
    Mark a file as copied or renamed for the next commit.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    94
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    95
diff [-r revision] [-r revision] [files ...]::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    96
    Generate a unified diff of the indicated files. If there are no 
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    97
    revisions specified, the working directory file is compared to 
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
    98
    the tip, one revision specified indicates a comparison between the 
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
    99
    working directory file and the specified revision, and two revisions 
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   100
    compares the two versions specified.
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   101
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   102
export [revision]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   103
    Print the changeset header (author, changeset hash, parent, and commit
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   104
    comment) and the diffs for a particular revision.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   105
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   106
forget [files]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   107
    Undo an 'hg add' scheduled for the next commit.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   108
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   109
heads::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   110
    Show all changesets with no children. These are the "heads" of
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   111
    development branches and are the usual targets for updates and merges.
196
48827121af7e add export, recover, and undo to the man page
jake@edge2.net
parents: 182
diff changeset
   112
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   113
history::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   114
    Print the revision history of the repository. Use the -v switch
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   115
    for more detail.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   116
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   117
identify::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   118
    Print a short identifier of the current state of the repo. This
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   119
    includes one or two parent hash identifiers, followed by
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   120
    a "+" if there are uncommitted changes in the working directory,
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   121
    followed by a list of tags for this revision
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   122
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   123
    aliases: id
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   124
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   125
import [-p <n> -b <base> -q] <patches>::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   126
    Import the listed patches and commit them individually.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   127
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   128
    options:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   129
    -p, --strip <n>   directory strip option for patch
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   130
    -b <path>         base directory to read patches from
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   131
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   132
    aliases: patch
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   133
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   134
init [-u] [source]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   135
    Initialize a repository in the current directory.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   136
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   137
    If a source is specified, pull that source into the repository.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   138
    This source is added to .hg/hgrc as the default for future pulls
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   139
    in this repository.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   140
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   141
    If the specified source is on the same filesystem, the repository
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   142
    will be copied via hardlinks. This is the fastest and most
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   143
    space-efficient mode of operation.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   144
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   145
    options:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   146
    -u, --update   update the working directory to match the tip
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   147
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   148
log <file>::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   149
    Print the revision history of the specified file.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   150
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   151
manifest [revision]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   152
    Print the indicated revision of the manifest (list of version controlled
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   153
    files)
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   154
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   155
parents::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   156
    Print the working directory's parent revisions.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   157
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   158
pull <repository path>::
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   159
    pull any changes from the specified repository to the repository in the
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   160
    current directory.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   161
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   162
    options:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   163
    -u, --update   update the working directory to tip after pull
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   164
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   165
push <destination>::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   166
    Push changes from the local repository to the specified
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   167
    destination. If the destination is local, this is identical to a
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   168
    a pull in that directory from the current directory.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   169
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   170
    The other currently available push method is SSH. This requires an
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   171
    accessible shell account on the destination machine and a copy of
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   172
    hg in the remote path. Destinations are specified in the following
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   173
    form:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   174
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   175
      ssh://[user@]host[:port]/path
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   176
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   177
rawcommit [-p -d -u -F -t -l]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   178
    Primarily useful for importing from other SCMs. 
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   179
196
48827121af7e add export, recover, and undo to the man page
jake@edge2.net
parents: 182
diff changeset
   180
recover::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   181
    Recover from an interrupted commit or pull. This should only be
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   182
    necessary when Mercurial suggests it.
196
48827121af7e add export, recover, and undo to the man page
jake@edge2.net
parents: 182
diff changeset
   183
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   184
remove [files ...]::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   185
    schedule the indicated files for removal from the repository at the next
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   186
    commit
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   187
 
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   188
    aliases: rm
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   189
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   190
serve [-a addr -n name -p port -t templatedir]::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   191
    Start a local HTTP repository browser and pull server.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   192
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   193
    options:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   194
    -a, --address <addr> address to use
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   195
    -p, --port <n>       port to use (default: 8000)
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   196
    -n, --name <name>    name to show in web pages (default: working dir)
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   197
    -t, --templatedir <path> web templates to use
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   198
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   199
status::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   200
    Show changed files in the working directory.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   201
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   202
    C = changed
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   203
    A = added
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   204
    R = removed
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   205
    ? = not tracked
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   206
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   207
tag [-t <text> -d <datecode> -u <user>] <name> [revision]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   208
    Add a tag <name> to the specified revision or the tip.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   209
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   210
    options:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   211
    -t, --text <text>     message for tag commit log entry
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   212
    -d, --date <datecode> datecode for commit
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   213
    -u, --user <user>     user for commit
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   214
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   215
tags::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   216
    List the current tags.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   217
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   218
tip::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   219
    Show the tip revision
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   220
196
48827121af7e add export, recover, and undo to the man page
jake@edge2.net
parents: 182
diff changeset
   221
undo::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   222
    Undo the last commit or pull transaction.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   223
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   224
update [-m -C] [revision]::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   225
    Update or merge the working directory to a specified revision.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   226
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   227
    If there are no outstanding changes in the working directory and
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   228
    there is a linear relationship between the current version and the
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   229
    requested version, the result is the requested version.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   230
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   231
    Otherwise the result is a merge between the contents of the
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   232
    current working directory and the requested version. Files that
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   233
    changed between either parent are marked as changed for the next
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   234
    commit and a commit must be performed before any further updates
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   235
    are allowed. Merging will not be performed without the -m flag.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   236
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   237
    The -C switch will tell Mercurial to forcibly update to the
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   238
    specified version, adding, removing, and overwriting locally
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   239
    changed fils as necessary.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   240
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   241
    options:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   242
    -m, --merge       allow merging of branches
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   243
    -C, --clean       overwrite locally modified files
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   244
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   245
    aliases: up checkout co
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   246
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   247
verify::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   248
    Verify the integrity of the current repository.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   249
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   250
    This will perform an extensive check of the repository's
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   251
    integrity, validating the hashes and checksums of each entry in
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   252
    the changelog, manifest, and tracked files, as well as the
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   253
    integrity of their crosslinks and indices.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   254
196
48827121af7e add export, recover, and undo to the man page
jake@edge2.net
parents: 182
diff changeset
   255
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   256
ENVIRONMENT VARIABLES
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   257
---------------------
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   258
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   259
HGMERGE::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   260
    An executable to use for resolving merge conflicts. The program ,
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   261
    will be executed with three arguments: local file, remote file,
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   262
    ancestor file.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   263
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   264
    The default program is "hgmerge", which is a shell script provided
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   265
    by Mercurial with some sensible defaults.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   266
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   267
HGUSER::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   268
    This is the string used for the author of a commit.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   269
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   270
EMAIL::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   271
    If HGUSER is not set, this will be used as the author for a commit.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   272
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   273
LOGNAME::
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   274
    if neither HGUSER nor EMAIL is set, LOGNAME will be used (with
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   275
    '@hostname' appended) as the author value for a commit.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   276
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   277
EDITOR::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   278
    This is the name of the editor to use when committing. Defaults to 'vi'.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   279
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   280
PYTHONPATH::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   281
    This is used by Python to find imported modules and may need to be set
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   282
    appropriately if Mercurial is not installed system-wide.
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   283
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   284
FILES
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   285
-----
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   286
 .hgignore::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   287
    This file contains regular expressions (one per line) that describe file
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   288
    names that should be ignored by hg
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   289
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   290
 .hgtags::
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   291
    This file contains changeset hash values and text tag names (one of each
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   292
    seperated by spaces) that correspond to tagged versions of the repository
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   293
    contents.
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   294
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   295
 $HOME/.hgrc, .hg/hgrc::
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   296
    This file contains defaults and configuration. Values in .hg/hgrc
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   297
    override those in .hgrc.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   298
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   299
NAMED REPOSITORIES
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   300
------------------
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   301
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   302
    To give symbolic names to a repository, create a section in .hgrc
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   303
    or .hg/hgrc containing assignments of names to paths.
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   304
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   305
    Example:
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   306
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   307
[paths]
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   308
hg = http://selenic.com/hg
181
038e4d8602bd updated for .hgpaths and http/old-http protocol name change
jake@edge2.net
parents: 177
diff changeset
   309
321
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   310
NON_TRANSPARENT PROXY SUPPORT
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   311
-----------------------------
321
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   312
438
b38deaf7873e Update docs
mpm@selenic.com
parents: 330
diff changeset
   313
    To access a Mercurial repository through a proxy,
321
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   314
    create a file $HOME/.hgrc in the following format:
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   315
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   316
[http_proxy]
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   317
host=myproxy:8080
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   318
user=<username>
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   319
passwd=<password>
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   320
no=<localhost1>,<localhost2>,<localhost3>,...
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   321
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   322
    "user","passwd" fields are used for authenticating proxies,
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   323
    "no" is a comma-separated list of local host names
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   324
    for which proxy must be bypassed.
73b8a8a059ec Transparent proxy support
mpm@selenic.com
parents: 196
diff changeset
   325
177
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   326
BUGS
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   327
----
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   328
Probably lots, please post them to the mailing list (See Resources below)
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   329
when you find them.
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   330
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   331
AUTHOR
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   332
------
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   333
Written by Matt Mackall <mpm@selenic.com>
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   334
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   335
RESOURCES
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   336
---------
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   337
http://selenic.com/mercurial[Main Web Site]
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   338
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   339
http://selenic.com/hg[Source code repository]
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   340
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   341
http://selenic.com/mailman/listinfo/mercurial[Mailing list]
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   342
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   343
COPYING
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   344
-------
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   345
Copyright (C) 2005 Matt Mackall.
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   346
Free use of this software is granted under the terms of the GNU General
91055f795d88 adding doc directory and files
jake@edge2.net
parents:
diff changeset
   347
Public License (GPL).