Mercurial > hg
annotate mercurial/help.py @ 6858:8f256bf98219
Add support for multiple possible bisect results (issue1228, issue1182)
The real reason for both issue is that bisect can not handle cases where there
are multiple possibilities for the result.
Example (from issue1228):
rev 0 -> good
rev 1 -> skipped
rev 2 -> skipped
rev 3 -> skipped
rev 4 -> bad
Note that this patch does not only fix the reported Assertion Error but also
the problem of a non converging bisect:
hg init
for i in `seq 3`; do echo $i > $i; hg add $i; hg ci -m$i; done
hg bisect -b 2
hg bisect -g 0
hg bisect -s
From this state on, you can:
a) mark as bad forever (non converging!)
b) mark as good to get an inconsistent state
c) skip for the Assertion Error
Minor description and code edits by pmezard.
author | Bernhard Leiner <bleiner@gmail.com> |
---|---|
date | Sat, 02 Aug 2008 22:10:10 +0200 |
parents | 1f733c2f0165 |
children | 2713e42dcf4e |
rev | line source |
---|---|
3795
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
1 # help.py - help data for mercurial |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
2 # |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
3 # Copyright 2006 Matt Mackall <mpm@selenic.com> |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
4 # |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
5 # This software may be used and distributed according to the terms |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
6 # of the GNU General Public License, incorporated herein by reference. |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
7 |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
8 helptable = { |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
9 "dates|Date Formats": |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
10 r''' |
6163
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
11 Some commands allow the user to specify a date: |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
12 backout, commit, import, tag: Specify the commit date. |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
13 log, revert, update: Select revision(s) by date. |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
14 |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
15 Many date formats are valid. Here are some examples: |
3795
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
16 |
3811 | 17 "Wed Dec 6 13:18:29 2006" (local timezone assumed) |
18 "Dec 6 13:18 -0600" (year assumed, time offset provided) | |
19 "Dec 6 13:18 UTC" (UTC and GMT are aliases for +0000) | |
20 "Dec 6" (midnight) | |
21 "13:18" (today assumed) | |
22 "3:39" (3:39AM assumed) | |
23 "3:39pm" (15:39) | |
24 "2006-12-6 13:18:29" (ISO 8601 format) | |
25 "2006-12-6 13:18" | |
26 "2006-12-6" | |
27 "12-6" | |
28 "12/6" | |
29 "12/6/6" (Dec 6 2006) | |
3795
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
30 |
3811 | 31 Lastly, there is Mercurial's internal format: |
3795
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
32 |
3811 | 33 "1165432709 0" (Wed Dec 6 13:18:29 2006 UTC) |
3795
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
34 |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
35 This is the internal representation format for dates. unixtime is |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
36 the number of seconds since the epoch (1970-01-01 00:00 UTC). offset |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
37 is the offset of the local timezone, in seconds west of UTC (negative |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
38 if the timezone is east of UTC). |
6163
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
39 |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
40 The log command also accepts date ranges: |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
41 |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
42 "<{date}" - on or before a given date |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
43 ">{date}" - on or after a given date |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
44 "{date} to {date}" - a date range, inclusive |
1f733c2f0165
Document log date ranges and mention 'hg help dates' for all commands (issue998)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
6009
diff
changeset
|
45 "-{days}" - within a given number of days of today |
3795
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
46 ''', |
3799 | 47 |
3798 | 48 'environment|env|Environment Variables': |
49 r''' | |
4686
849f011dbf79
Remember path to 'hg' executable and pass to external tools and hooks as $HG.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
3913
diff
changeset
|
50 HG:: |
5062
3d35c8cb5eb4
Simplify/correct finding the hg executable (fixes issue644)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
4686
diff
changeset
|
51 Path to the 'hg' executable, automatically passed when running hooks, |
3d35c8cb5eb4
Simplify/correct finding the hg executable (fixes issue644)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
4686
diff
changeset
|
52 extensions or external tools. If unset or empty, an executable named |
3d35c8cb5eb4
Simplify/correct finding the hg executable (fixes issue644)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
4686
diff
changeset
|
53 'hg' (with com/exe/bat/cmd extension on Windows) is searched. |
4686
849f011dbf79
Remember path to 'hg' executable and pass to external tools and hooks as $HG.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
3913
diff
changeset
|
54 |
3798 | 55 HGEDITOR:: |
5660
3c80ecdc1bcd
Use VISUAL in addition to EDITOR when choosing the editor to use.
Osku Salerma <osku@iki.fi>
parents:
5062
diff
changeset
|
56 This is the name of the editor to use when committing. See EDITOR. |
3798 | 57 |
58 (deprecated, use .hgrc) | |
59 | |
60 HGENCODING:: | |
61 This overrides the default locale setting detected by Mercurial. | |
62 This setting is used to convert data including usernames, | |
63 changeset descriptions, tag names, and branches. This setting can | |
64 be overridden with the --encoding command-line option. | |
65 | |
66 HGENCODINGMODE:: | |
67 This sets Mercurial's behavior for handling unknown characters | |
68 while transcoding user inputs. The default is "strict", which | |
69 causes Mercurial to abort if it can't translate a character. Other | |
70 settings include "replace", which replaces unknown characters, and | |
71 "ignore", which drops them. This setting can be overridden with | |
72 the --encodingmode command-line option. | |
73 | |
74 HGMERGE:: | |
75 An executable to use for resolving merge conflicts. The program | |
76 will be executed with three arguments: local file, remote file, | |
77 ancestor file. | |
78 | |
79 (deprecated, use .hgrc) | |
80 | |
81 HGRCPATH:: | |
82 A list of files or directories to search for hgrc files. Item | |
83 separator is ":" on Unix, ";" on Windows. If HGRCPATH is not set, | |
84 platform default search path is used. If empty, only .hg/hgrc of | |
85 current repository is read. | |
86 | |
87 For each element in path, if a directory, all entries in directory | |
88 ending with ".rc" are added to path. Else, element itself is | |
89 added to path. | |
90 | |
91 HGUSER:: | |
92 This is the string used for the author of a commit. | |
93 | |
94 (deprecated, use .hgrc) | |
95 | |
96 EMAIL:: | |
97 If HGUSER is not set, this will be used as the author for a commit. | |
98 | |
99 LOGNAME:: | |
100 If neither HGUSER nor EMAIL is set, LOGNAME will be used (with | |
101 '@hostname' appended) as the author value for a commit. | |
102 | |
5660
3c80ecdc1bcd
Use VISUAL in addition to EDITOR when choosing the editor to use.
Osku Salerma <osku@iki.fi>
parents:
5062
diff
changeset
|
103 VISUAL:: |
3c80ecdc1bcd
Use VISUAL in addition to EDITOR when choosing the editor to use.
Osku Salerma <osku@iki.fi>
parents:
5062
diff
changeset
|
104 This is the name of the editor to use when committing. See EDITOR. |
3c80ecdc1bcd
Use VISUAL in addition to EDITOR when choosing the editor to use.
Osku Salerma <osku@iki.fi>
parents:
5062
diff
changeset
|
105 |
3798 | 106 EDITOR:: |
6009
f077815932ce
filemerge: remove the hgmerge script
Matt Mackall <mpm@selenic.com>
parents:
5660
diff
changeset
|
107 Sometimes Mercurial needs to open a text file in an editor |
f077815932ce
filemerge: remove the hgmerge script
Matt Mackall <mpm@selenic.com>
parents:
5660
diff
changeset
|
108 for a user to modify, for example when writing commit messages. |
f077815932ce
filemerge: remove the hgmerge script
Matt Mackall <mpm@selenic.com>
parents:
5660
diff
changeset
|
109 The editor it uses is determined by looking at the environment |
f077815932ce
filemerge: remove the hgmerge script
Matt Mackall <mpm@selenic.com>
parents:
5660
diff
changeset
|
110 variables HGEDITOR, VISUAL and EDITOR, in that order. The first |
f077815932ce
filemerge: remove the hgmerge script
Matt Mackall <mpm@selenic.com>
parents:
5660
diff
changeset
|
111 non-empty one is chosen. If all of them are empty, the editor |
5660
3c80ecdc1bcd
Use VISUAL in addition to EDITOR when choosing the editor to use.
Osku Salerma <osku@iki.fi>
parents:
5062
diff
changeset
|
112 defaults to 'vi'. |
3798 | 113 |
114 PYTHONPATH:: | |
115 This is used by Python to find imported modules and may need to be set | |
116 appropriately if Mercurial is not installed system-wide. | |
3799 | 117 ''', |
118 | |
119 "patterns|File Name Patterns": r''' | |
120 Mercurial accepts several notations for identifying one or more | |
121 files at a time. | |
122 | |
123 By default, Mercurial treats filenames as shell-style extended | |
124 glob patterns. | |
125 | |
126 Alternate pattern notations must be specified explicitly. | |
127 | |
128 To use a plain path name without any pattern matching, start a | |
129 name with "path:". These path names must match completely, from | |
130 the root of the current repository. | |
131 | |
132 To use an extended glob, start a name with "glob:". Globs are | |
133 rooted at the current directory; a glob such as "*.c" will match | |
134 files ending in ".c" in the current directory only. | |
135 | |
136 The supported glob syntax extensions are "**" to match any string | |
137 across path separators, and "{a,b}" to mean "a or b". | |
138 | |
139 To use a Perl/Python regular expression, start a name with "re:". | |
140 Regexp pattern matching is anchored at the root of the repository. | |
141 | |
142 Plain examples: | |
143 | |
144 path:foo/bar a name bar in a directory named foo in the root of | |
145 the repository | |
146 path:path:name a file or directory named "path:name" | |
147 | |
148 Glob examples: | |
149 | |
150 glob:*.c any name ending in ".c" in the current directory | |
151 *.c any name ending in ".c" in the current directory | |
152 **.c any name ending in ".c" in the current directory, or | |
153 any subdirectory | |
154 foo/*.c any name ending in ".c" in the directory foo | |
155 foo/**.c any name ending in ".c" in the directory foo, or any | |
156 subdirectory | |
157 | |
158 Regexp examples: | |
159 | |
160 re:.*\.c$ any name ending in ".c", anywhere in the repository | |
161 | |
162 ''', | |
3795
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
163 } |
17a11f4ff260
Add basic support for help topics and a dates topic
Matt Mackall <mpm@selenic.com>
parents:
diff
changeset
|
164 |