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