Mercurial > hg
annotate doc/hg.1.txt @ 2281:7761597b5da3
prompt user for http authentication info
in interactive mode, mercurial now asks the user for the username and
password when the server requires it. the previous behavior was to fail
with an http 401.
based on patch from eric jaffe <jaffe.eric@gmail.com>.
author | Vadim Gelfer <vadim.gelfer@gmail.com> |
---|---|
date | Sun, 14 May 2006 17:37:17 -0700 |
parents | 956e329f9e13 |
children | d90a9d7c7d4d |
rev | line source |
---|---|
177 | 1 HG(1) |
2 ===== | |
3 Matt Mackall <mpm@selenic.com> | |
4 | |
5 NAME | |
6 ---- | |
438 | 7 hg - Mercurial source code management system |
177 | 8 |
9 SYNOPSIS | |
10 -------- | |
11 'hg' [-v -d -q -y] <command> [command options] [files] | |
12 | |
13 DESCRIPTION | |
14 ----------- | |
15 The hg(1) command provides a command line interface to the Mercurial system. | |
16 | |
17 COMMAND ELEMENTS | |
18 ---------------- | |
19 | |
20 files ...:: | |
724
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
21 indicates one or more filename or relative path filenames; see |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
22 "FILE NAME PATTERNS" for information on pattern matching |
177 | 23 |
24 path:: | |
25 indicates a path on the local machine | |
26 | |
478
f1804f2e7f35
Update of doc/hg.1.txt
Thomas Arendsen Hein <thomas@intevation.de>
parents:
438
diff
changeset
|
27 revision:: |
438 | 28 indicates a changeset which can be specified as a changeset revision |
29 number, a tag, or a unique substring of the changeset hash value | |
177 | 30 |
31 repository path:: | |
498 | 32 either the pathname of a local repository or the URI of a remote |
181
038e4d8602bd
updated for .hgpaths and http/old-http protocol name change
jake@edge2.net
parents:
177
diff
changeset
|
33 repository. There are two available URI protocols, http:// which is |
478
f1804f2e7f35
Update of doc/hg.1.txt
Thomas Arendsen Hein <thomas@intevation.de>
parents:
438
diff
changeset
|
34 fast and the old-http:// protocol which is much slower but does not |
438 | 35 require a special server on the web host. |
177 | 36 |
438 | 37 |
1814
7956893e8458
generate hg manpage from commands.py docstring
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
1758
diff
changeset
|
38 include::hg.1.gendoc.txt[] |
438 | 39 |
724
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
40 FILE NAME PATTERNS |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
41 ------------------ |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
42 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
43 Mercurial accepts several notations for identifying one or more |
1274 | 44 files at a time. |
724
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
45 |
1274 | 46 By default, Mercurial treats filenames as shell-style extended |
724
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
47 glob patterns. |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
48 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
49 Alternate pattern notations must be specified explicitly. |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
50 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
51 To use a plain path name without any pattern matching, start a |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
52 name with "path:". These path names must match completely, from |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
53 the root of the current repository. |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
54 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
55 To use an extended glob, start a name with "glob:". Globs are |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
56 rooted at the current directory; a glob such as "*.c" will match |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
57 files ending in ".c" in the current directory only. |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
58 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
59 The supported glob syntax extensions are "**" to match any string |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
60 across path separators, and "{a,b}" to mean "a or b". |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
61 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
62 To use a Perl/Python regular expression, start a name with "re:". |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
63 Regexp pattern matching is anchored at the root of the repository. |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
64 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
65 Plain examples: |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
66 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
67 path:foo/bar a name bar in a directory named foo in the root of |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
68 the repository |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
69 path:path:name a file or directory named "path:name" |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
70 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
71 Glob examples: |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
72 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
73 glob:*.c any name ending in ".c" in the current directory |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
74 *.c any name ending in ".c" in the current directory |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
75 **.c any name ending in ".c" in the current directory, or |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
76 any subdirectory |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
77 foo/*.c any name ending in ".c" in the directory foo |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
78 foo/**.c any name ending in ".c" in the directory foo, or any |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
79 subdirectory |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
80 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
81 Regexp examples: |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
82 |
1045
b35d5b86e240
run the doc/* through aspell.
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
1036
diff
changeset
|
83 re:.*\.c$ any name ending in ".c", anywhere in the repository |
724
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
84 |
1c0c413cccdd
Get add and locate to use new repo and dirstate walk code.
Bryan O'Sullivan <bos@serpentine.com>
parents:
671
diff
changeset
|
85 |
580 | 86 SPECIFYING SINGLE REVISIONS |
87 --------------------------- | |
88 | |
89 Mercurial accepts several notations for identifying individual | |
90 revisions. | |
91 | |
92 A plain integer is treated as a revision number. Negative | |
93 integers are treated as offsets from the tip, with -1 denoting the | |
94 tip. | |
95 | |
96 A 40-digit hexadecimal string is treated as a unique revision | |
97 identifier. | |
98 | |
99 A hexadecimal string less than 40 characters long is treated as a | |
100 unique revision identifier, and referred to as a short-form | |
101 identifier. A short-form identifier is only valid if it is the | |
102 prefix of one full-length identifier. | |
103 | |
104 Any other string is treated as a tag name, which is a symbolic | |
105 name associated with a revision identifier. Tag names may not | |
106 contain the ":" character. | |
107 | |
108 The reserved name "tip" is a special tag that always identifies | |
109 the most recent revision. | |
110 | |
111 SPECIFYING MULTIPLE REVISIONS | |
112 ----------------------------- | |
113 | |
114 When Mercurial accepts more than one revision, they may be | |
115 specified individually, or provided as a continuous range, | |
116 separated by the ":" character. | |
117 | |
118 The syntax of range notation is [BEGIN]:[END], where BEGIN and END | |
119 are revision identifiers. Both BEGIN and END are optional. If | |
120 BEGIN is not specified, it defaults to revision number 0. If END | |
121 is not specified, it defaults to the tip. The range ":" thus | |
122 means "all revisions". | |
123 | |
124 If BEGIN is greater than END, revisions are treated in reverse | |
125 order. | |
126 | |
860
8ccbac05cf59
Use correct term "closed interval" for ranges.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
840
diff
changeset
|
127 A range acts as a closed interval. This means that a range of 3:5 |
580 | 128 gives 3, 4 and 5. Similarly, a range of 4:2 gives 4, 3, and 2. |
196
48827121af7e
add export, recover, and undo to the man page
jake@edge2.net
parents:
182
diff
changeset
|
129 |
177 | 130 ENVIRONMENT VARIABLES |
131 --------------------- | |
438 | 132 |
478
f1804f2e7f35
Update of doc/hg.1.txt
Thomas Arendsen Hein <thomas@intevation.de>
parents:
438
diff
changeset
|
133 HGEDITOR:: |
f1804f2e7f35
Update of doc/hg.1.txt
Thomas Arendsen Hein <thomas@intevation.de>
parents:
438
diff
changeset
|
134 This is the name of the editor to use when committing. Defaults to the |
1216
1639fc7c2ccf
Cleanup of tabs and trailing spaces in documentation.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
1212
diff
changeset
|
135 value of EDITOR. |
608
d2994b5298fb
Add username/merge/editor to .hgrc
Matt Mackall <mpm@selenic.com>
parents:
606
diff
changeset
|
136 |
d2994b5298fb
Add username/merge/editor to .hgrc
Matt Mackall <mpm@selenic.com>
parents:
606
diff
changeset
|
137 (deprecated, use .hgrc) |
478
f1804f2e7f35
Update of doc/hg.1.txt
Thomas Arendsen Hein <thomas@intevation.de>
parents:
438
diff
changeset
|
138 |
177 | 139 HGMERGE:: |
498 | 140 An executable to use for resolving merge conflicts. The program |
438 | 141 will be executed with three arguments: local file, remote file, |
142 ancestor file. | |
143 | |
144 The default program is "hgmerge", which is a shell script provided | |
145 by Mercurial with some sensible defaults. | |
177 | 146 |
608
d2994b5298fb
Add username/merge/editor to .hgrc
Matt Mackall <mpm@selenic.com>
parents:
606
diff
changeset
|
147 (deprecated, use .hgrc) |
d2994b5298fb
Add username/merge/editor to .hgrc
Matt Mackall <mpm@selenic.com>
parents:
606
diff
changeset
|
148 |
1951
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
149 HGRCPATH:: |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
150 A list of files or directories to search for hgrc files. Item |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
151 separator is ":" on Unix, ";" on Windows. If HGRCPATH is not set, |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
152 platform default search path is used. If empty, only .hg/hgrc of |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
153 current repository is read. |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
154 |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
155 For each element in path, if a directory, all entries in directory |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
156 ending with ".rc" are added to path. Else, element itself is |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
157 added to path. |
696230e52e4d
add HGRCPATH env var, list of places to look for hgrc files.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
1920
diff
changeset
|
158 |
177 | 159 HGUSER:: |
438 | 160 This is the string used for the author of a commit. |
177 | 161 |
608
d2994b5298fb
Add username/merge/editor to .hgrc
Matt Mackall <mpm@selenic.com>
parents:
606
diff
changeset
|
162 (deprecated, use .hgrc) |
d2994b5298fb
Add username/merge/editor to .hgrc
Matt Mackall <mpm@selenic.com>
parents:
606
diff
changeset
|
163 |
177 | 164 EMAIL:: |
438 | 165 If HGUSER is not set, this will be used as the author for a commit. |
177 | 166 |
167 LOGNAME:: | |
478
f1804f2e7f35
Update of doc/hg.1.txt
Thomas Arendsen Hein <thomas@intevation.de>
parents:
438
diff
changeset
|
168 If neither HGUSER nor EMAIL is set, LOGNAME will be used (with |
438 | 169 '@hostname' appended) as the author value for a commit. |
177 | 170 |
171 EDITOR:: | |
478
f1804f2e7f35
Update of doc/hg.1.txt
Thomas Arendsen Hein <thomas@intevation.de>
parents:
438
diff
changeset
|
172 This is the name of the editor used in the hgmerge script. It will be |
498 | 173 used for commit messages if HGEDITOR isn't set. Defaults to 'vi'. |
438 | 174 |
175 PYTHONPATH:: | |
176 This is used by Python to find imported modules and may need to be set | |
177 appropriately if Mercurial is not installed system-wide. | |
177 | 178 |
179 FILES | |
180 ----- | |
181 .hgignore:: | |
438 | 182 This file contains regular expressions (one per line) that describe file |
2209
956e329f9e13
document hgignore syntax in new file doc/hgignore.5.txt.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
2031
diff
changeset
|
183 names that should be ignored by hg. For details, see hgignore(5). |
177 | 184 |
185 .hgtags:: | |
438 | 186 This file contains changeset hash values and text tag names (one of each |
1045
b35d5b86e240
run the doc/* through aspell.
Benoit Boissinot <benoit.boissinot@ens-lyon.org>
parents:
1036
diff
changeset
|
187 separated by spaces) that correspond to tagged versions of the repository |
177 | 188 contents. |
189 | |
951
859de3ebc041
Read global config file /etc/mercurial/hgrc and fix reading hgrc on Windows.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
940
diff
changeset
|
190 /etc/mercurial/hgrc, $HOME/.hgrc, .hg/hgrc:: |
438 | 191 This file contains defaults and configuration. Values in .hg/hgrc |
951
859de3ebc041
Read global config file /etc/mercurial/hgrc and fix reading hgrc on Windows.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
940
diff
changeset
|
192 override those in $HOME/.hgrc, and these override settings made in the |
859de3ebc041
Read global config file /etc/mercurial/hgrc and fix reading hgrc on Windows.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
940
diff
changeset
|
193 global /etc/mercurial/hgrc configuration. See hgrc(5) for details of |
859de3ebc041
Read global config file /etc/mercurial/hgrc and fix reading hgrc on Windows.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
940
diff
changeset
|
194 the contents and format of these files. |
321 | 195 |
177 | 196 BUGS |
197 ---- | |
198 Probably lots, please post them to the mailing list (See Resources below) | |
199 when you find them. | |
200 | |
671
efa4a7e2f322
Move hgrc documentation out to its own man page, hgrc(5).
Bryan O'Sullivan <bos@serpentine.com>
parents:
631
diff
changeset
|
201 SEE ALSO |
efa4a7e2f322
Move hgrc documentation out to its own man page, hgrc(5).
Bryan O'Sullivan <bos@serpentine.com>
parents:
631
diff
changeset
|
202 -------- |
2209
956e329f9e13
document hgignore syntax in new file doc/hgignore.5.txt.
Vadim Gelfer <vadim.gelfer@gmail.com>
parents:
2031
diff
changeset
|
203 hgignore(5), hgrc(5) |
671
efa4a7e2f322
Move hgrc documentation out to its own man page, hgrc(5).
Bryan O'Sullivan <bos@serpentine.com>
parents:
631
diff
changeset
|
204 |
177 | 205 AUTHOR |
206 ------ | |
207 Written by Matt Mackall <mpm@selenic.com> | |
208 | |
209 RESOURCES | |
210 --------- | |
211 http://selenic.com/mercurial[Main Web Site] | |
212 | |
213 http://selenic.com/hg[Source code repository] | |
214 | |
215 http://selenic.com/mailman/listinfo/mercurial[Mailing list] | |
216 | |
217 COPYING | |
218 ------- | |
1341 | 219 Copyright \(C) 2005 Matt Mackall. |
177 | 220 Free use of this software is granted under the terms of the GNU General |
221 Public License (GPL). |