Show More
@@ -3265,8 +3265,12 b' def help_(ui, name=None, unknowncmd=Fals' | |||
|
3265 | 3265 | rst.append(_('\nuse "hg help %s" to show the full help text\n') |
|
3266 | 3266 | % name) |
|
3267 | 3267 | elif not ui.quiet: |
|
3268 |
|
|
|
3269 |
% name |
|
|
3268 | omitted = _('use "hg -v help %s" to show more complete' | |
|
3269 | ' help and the global options') % name | |
|
3270 | notomitted = _('use "hg -v help %s" to show' | |
|
3271 | ' the global options') % name | |
|
3272 | help.indicateomitted(rst, omitted, notomitted) | |
|
3273 | ||
|
3270 | 3274 | return rst |
|
3271 | 3275 | |
|
3272 | 3276 | |
@@ -3369,6 +3373,11 b' def help_(ui, name=None, unknowncmd=Fals' | |||
|
3369 | 3373 | if util.safehasattr(doc, '__call__'): |
|
3370 | 3374 | rst += [" %s\n" % l for l in doc().splitlines()] |
|
3371 | 3375 | |
|
3376 | if not ui.verbose: | |
|
3377 | omitted = (_('use "hg help -v %s" to show more complete help') % | |
|
3378 | name) | |
|
3379 | help.indicateomitted(rst, omitted) | |
|
3380 | ||
|
3372 | 3381 | try: |
|
3373 | 3382 | cmdutil.findcmd(name, table) |
|
3374 | 3383 | rst.append(_('\nuse "hg help -c %s" to see help for ' |
@@ -3396,6 +3405,11 b' def help_(ui, name=None, unknowncmd=Fals' | |||
|
3396 | 3405 | rst.extend(tail.splitlines(True)) |
|
3397 | 3406 | rst.append('\n') |
|
3398 | 3407 | |
|
3408 | if not ui.verbose: | |
|
3409 | omitted = (_('use "hg help -v %s" to show more complete help') % | |
|
3410 | name) | |
|
3411 | help.indicateomitted(rst, omitted) | |
|
3412 | ||
|
3399 | 3413 | if mod: |
|
3400 | 3414 | try: |
|
3401 | 3415 | ct = mod.cmdtable |
@@ -3459,7 +3473,13 b' def help_(ui, name=None, unknowncmd=Fals' | |||
|
3459 | 3473 | rst.extend(helplist()) |
|
3460 | 3474 | |
|
3461 | 3475 | keep = ui.verbose and ['verbose'] or [] |
|
3462 | formatted, pruned = minirst.format(''.join(rst), textwidth, keep=keep) | |
|
3476 | text = ''.join(rst) | |
|
3477 | formatted, pruned = minirst.format(text, textwidth, keep=keep) | |
|
3478 | if 'verbose' in pruned: | |
|
3479 | keep.append('omitted') | |
|
3480 | else: | |
|
3481 | keep.append('notomitted') | |
|
3482 | formatted, pruned = minirst.format(text, textwidth, keep=keep) | |
|
3463 | 3483 | ui.write(formatted) |
|
3464 | 3484 | |
|
3465 | 3485 |
@@ -61,6 +61,11 b' def optrst(options, verbose):' | |||
|
61 | 61 | |
|
62 | 62 | return ''.join(rst) |
|
63 | 63 | |
|
64 | def indicateomitted(rst, omitted, notomitted=None): | |
|
65 | rst.append('\n\n.. container:: omitted\n\n %s\n\n' % omitted) | |
|
66 | if notomitted: | |
|
67 | rst.append('\n\n.. container:: notomitted\n\n %s\n\n' % notomitted) | |
|
68 | ||
|
64 | 69 | def topicmatch(kw): |
|
65 | 70 | """Return help topics matching kw. |
|
66 | 71 |
@@ -261,7 +261,7 b'' | |||
|
261 | 261 | --datesort try to sort changesets by date |
|
262 | 262 | --sourcesort preserve source changesets order |
|
263 | 263 | |
|
264 |
use "hg -v help convert" to show |
|
|
264 | use "hg -v help convert" to show the global options | |
|
265 | 265 | $ hg init a |
|
266 | 266 | $ cd a |
|
267 | 267 | $ echo a > a |
@@ -59,7 +59,7 b' check alignment of option descriptions i' | |||
|
59 | 59 | \xe9\x95\xb7\xe3\x81\x84\xe9\x95\xb7\xe3\x81\x84\xe5\x90\x8d\xe5\x89\x8d \xe9\x95\xb7\xe3\x81\x84\xe9\x95\xb7\xe3\x81\x84\xe5\x90\x8d\xe5\x89\x8d \xe9\x95\xb7\xe3\x81\x84\xe9\x95\xb7\xe3\x81\x84\xe5\x90\x8d\xe5\x89\x8d \xe9\x95\xb7\xe3\x81\x84\xe9\x95\xb7\xe3\x81\x84\xe5\x90\x8d\xe5\x89\x8d (esc) |
|
60 | 60 | \xe9\x95\xb7\xe3\x81\x84\xe9\x95\xb7\xe3\x81\x84\xe5\x90\x8d\xe5\x89\x8d (esc) |
|
61 | 61 | |
|
62 |
use "hg -v help showoptlist" to show |
|
|
62 | use "hg -v help showoptlist" to show the global options | |
|
63 | 63 | |
|
64 | 64 | |
|
65 | 65 | $ rm -f s; touch s |
@@ -67,7 +67,7 b' define commands to display help text' | |||
|
67 | 67 | \x82\xa0\x82\xa2\x82\xa4\x82\xa6\x82\xa8\x82\xa9\x82\xab\x82\xad\x82\xaf\x82\xa0\x82\xa2\x82\xa4\x82\xa6\x82\xa8\x82\xa9\x82\xab\x82\xad\x82\xaf\x82\xa0\x82\xa2\x82\xa4\x82\xa6\x82\xa8\x82\xa9\x82\xab\x82\xad\x82\xaf (esc) |
|
68 | 68 | \x82\xa0\x82\xa2\x82\xa4\x82\xa6\x82\xa8\x82\xa9\x82\xab\x82\xad\x82\xaf (esc) |
|
69 | 69 | |
|
70 |
use "hg -v help show_full_ja" to show |
|
|
70 | use "hg -v help show_full_ja" to show the global options | |
|
71 | 71 | |
|
72 | 72 | (1-2) display Japanese full-width characters in utf-8 |
|
73 | 73 | |
@@ -82,7 +82,7 b' define commands to display help text' | |||
|
82 | 82 | \xe3\x81\x82\xe3\x81\x84\xe3\x81\x86\xe3\x81\x88\xe3\x81\x8a\xe3\x81\x8b\xe3\x81\x8d\xe3\x81\x8f\xe3\x81\x91\xe3\x81\x82\xe3\x81\x84\xe3\x81\x86\xe3\x81\x88\xe3\x81\x8a\xe3\x81\x8b\xe3\x81\x8d\xe3\x81\x8f\xe3\x81\x91\xe3\x81\x82\xe3\x81\x84\xe3\x81\x86\xe3\x81\x88\xe3\x81\x8a\xe3\x81\x8b\xe3\x81\x8d\xe3\x81\x8f\xe3\x81\x91 (esc) |
|
83 | 83 | \xe3\x81\x82\xe3\x81\x84\xe3\x81\x86\xe3\x81\x88\xe3\x81\x8a\xe3\x81\x8b\xe3\x81\x8d\xe3\x81\x8f\xe3\x81\x91 (esc) |
|
84 | 84 | |
|
85 |
use "hg -v help show_full_ja" to show |
|
|
85 | use "hg -v help show_full_ja" to show the global options | |
|
86 | 86 | |
|
87 | 87 | |
|
88 | 88 | (1-3) display Japanese half-width characters in cp932 |
@@ -98,7 +98,7 b' define commands to display help text' | |||
|
98 | 98 | \xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9 (esc) |
|
99 | 99 | \xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8\xb9 (esc) |
|
100 | 100 | |
|
101 |
use "hg -v help show_half_ja" to show |
|
|
101 | use "hg -v help show_half_ja" to show the global options | |
|
102 | 102 | |
|
103 | 103 | (1-4) display Japanese half-width characters in utf-8 |
|
104 | 104 | |
@@ -113,7 +113,7 b' define commands to display help text' | |||
|
113 | 113 | \xef\xbd\xb1\xef\xbd\xb2\xef\xbd\xb3\xef\xbd\xb4\xef\xbd\xb5\xef\xbd\xb6\xef\xbd\xb7\xef\xbd\xb8\xef\xbd\xb9\xef\xbd\xb1\xef\xbd\xb2\xef\xbd\xb3\xef\xbd\xb4\xef\xbd\xb5\xef\xbd\xb6\xef\xbd\xb7\xef\xbd\xb8\xef\xbd\xb9\xef\xbd\xb1\xef\xbd\xb2\xef\xbd\xb3\xef\xbd\xb4\xef\xbd\xb5\xef\xbd\xb6\xef\xbd\xb7\xef\xbd\xb8\xef\xbd\xb9\xef\xbd\xb1\xef\xbd\xb2\xef\xbd\xb3\xef\xbd\xb4\xef\xbd\xb5\xef\xbd\xb6\xef\xbd\xb7\xef\xbd\xb8\xef\xbd\xb9\xef\xbd\xb1\xef\xbd\xb2\xef\xbd\xb3\xef\xbd\xb4\xef\xbd\xb5\xef\xbd\xb6\xef\xbd\xb7\xef\xbd\xb8\xef\xbd\xb9\xef\xbd\xb1\xef\xbd\xb2\xef\xbd\xb3\xef\xbd\xb4\xef\xbd\xb5\xef\xbd\xb6\xef\xbd\xb7\xef\xbd\xb8\xef\xbd\xb9 (esc) |
|
114 | 114 | \xef\xbd\xb1\xef\xbd\xb2\xef\xbd\xb3\xef\xbd\xb4\xef\xbd\xb5\xef\xbd\xb6\xef\xbd\xb7\xef\xbd\xb8\xef\xbd\xb9\xef\xbd\xb1\xef\xbd\xb2\xef\xbd\xb3\xef\xbd\xb4\xef\xbd\xb5\xef\xbd\xb6\xef\xbd\xb7\xef\xbd\xb8\xef\xbd\xb9 (esc) |
|
115 | 115 | |
|
116 |
use "hg -v help show_half_ja" to show |
|
|
116 | use "hg -v help show_half_ja" to show the global options | |
|
117 | 117 | |
|
118 | 118 | |
|
119 | 119 | |
@@ -134,7 +134,7 b' define commands to display help text' | |||
|
134 | 134 | \x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b\x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b\x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b\x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b\x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b\x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b (esc) |
|
135 | 135 | \x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b (esc) |
|
136 | 136 | |
|
137 |
use "hg -v help show_ambig_ja" to show |
|
|
137 | use "hg -v help show_ambig_ja" to show the global options | |
|
138 | 138 | |
|
139 | 139 | (2-1-2) display Japanese ambiguous-width characters in utf-8 |
|
140 | 140 | |
@@ -149,7 +149,7 b' define commands to display help text' | |||
|
149 | 149 | \xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b\xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b\xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b\xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b\xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b\xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b (esc) |
|
150 | 150 | \xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b (esc) |
|
151 | 151 | |
|
152 |
use "hg -v help show_ambig_ja" to show |
|
|
152 | use "hg -v help show_ambig_ja" to show the global options | |
|
153 | 153 | |
|
154 | 154 | (2-1-3) display Russian ambiguous-width characters in cp1251 |
|
155 | 155 | |
@@ -164,7 +164,7 b' define commands to display help text' | |||
|
164 | 164 | \xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8\xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8\xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8\xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8\xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8\xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8 (esc) |
|
165 | 165 | \xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8 (esc) |
|
166 | 166 | |
|
167 |
use "hg -v help show_ambig_ru" to show |
|
|
167 | use "hg -v help show_ambig_ru" to show the global options | |
|
168 | 168 | |
|
169 | 169 | (2-1-4) display Russian ambiguous-width characters in utf-8 |
|
170 | 170 | |
@@ -179,7 +179,7 b' define commands to display help text' | |||
|
179 | 179 | \xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8\xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8\xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8\xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8\xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8\xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8 (esc) |
|
180 | 180 | \xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8 (esc) |
|
181 | 181 | |
|
182 |
use "hg -v help show_ambig_ru" to show |
|
|
182 | use "hg -v help show_ambig_ru" to show the global options | |
|
183 | 183 | |
|
184 | 184 | |
|
185 | 185 | (2-2) treat width of ambiguous characters as wide |
@@ -200,7 +200,7 b' define commands to display help text' | |||
|
200 | 200 | \x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b\x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b\x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b (esc) |
|
201 | 201 | \x83\xbf\x83\xc0\x83\xc1\x83\xc2\x83\xd2\x83\xc4\x83\xc5\x83\xc6\x81\x9b (esc) |
|
202 | 202 | |
|
203 |
use "hg -v help show_ambig_ja" to show |
|
|
203 | use "hg -v help show_ambig_ja" to show the global options | |
|
204 | 204 | |
|
205 | 205 | (2-2-2) display Japanese ambiguous-width characters in utf-8 |
|
206 | 206 | |
@@ -218,7 +218,7 b' define commands to display help text' | |||
|
218 | 218 | \xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b\xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b\xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b (esc) |
|
219 | 219 | \xce\xb1\xce\xb2\xce\xb3\xce\xb4\xcf\x85\xce\xb6\xce\xb7\xce\xb8\xe2\x97\x8b (esc) |
|
220 | 220 | |
|
221 |
use "hg -v help show_ambig_ja" to show |
|
|
221 | use "hg -v help show_ambig_ja" to show the global options | |
|
222 | 222 | |
|
223 | 223 | (2-2-3) display Russian ambiguous-width characters in cp1251 |
|
224 | 224 | |
@@ -236,7 +236,7 b' define commands to display help text' | |||
|
236 | 236 | \xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8\xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8\xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8 (esc) |
|
237 | 237 | \xcd\xe0\xf1\xf2\xf0\xee\xe9\xea\xe8 (esc) |
|
238 | 238 | |
|
239 |
use "hg -v help show_ambig_ru" to show |
|
|
239 | use "hg -v help show_ambig_ru" to show the global options | |
|
240 | 240 | |
|
241 | 241 | (2-2-4) display Russian ambiguous-width charactes in utf-8 |
|
242 | 242 | |
@@ -254,6 +254,6 b' define commands to display help text' | |||
|
254 | 254 | \xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8\xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8\xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8 (esc) |
|
255 | 255 | \xd0\x9d\xd0\xb0\xd1\x81\xd1\x82\xd1\x80\xd0\xbe\xd0\xb9\xd0\xba\xd0\xb8 (esc) |
|
256 | 256 | |
|
257 |
use "hg -v help show_ambig_ru" to show |
|
|
257 | use "hg -v help show_ambig_ru" to show the global options | |
|
258 | 258 | |
|
259 | 259 | $ cd .. |
@@ -47,7 +47,7 b' Should diff cloned directories:' | |||
|
47 | 47 | |
|
48 | 48 | [+] marked option can be specified multiple times |
|
49 | 49 | |
|
50 |
use "hg -v help falabala" to show |
|
|
50 | use "hg -v help falabala" to show the global options | |
|
51 | 51 | |
|
52 | 52 | $ hg ci -d '0 0' -mtest1 |
|
53 | 53 |
@@ -269,7 +269,7 b' Extension module help vs command help:' | |||
|
269 | 269 | |
|
270 | 270 | [+] marked option can be specified multiple times |
|
271 | 271 | |
|
272 |
use "hg -v help extdiff" to show |
|
|
272 | use "hg -v help extdiff" to show the global options | |
|
273 | 273 | |
|
274 | 274 | $ hg help --extension extdiff |
|
275 | 275 | extdiff extension - command to allow external programs to compare revisions |
@@ -372,7 +372,7 b' Test help topic with same name as extens' | |||
|
372 | 372 | |
|
373 | 373 | multirevs command |
|
374 | 374 | |
|
375 |
use "hg -v help multirevs" to show |
|
|
375 | use "hg -v help multirevs" to show the global options | |
|
376 | 376 | |
|
377 | 377 | $ hg multirevs |
|
378 | 378 | hg multirevs: invalid arguments |
@@ -279,7 +279,7 b' Test short command list with verbose opt' | |||
|
279 | 279 | |
|
280 | 280 | [+] marked option can be specified multiple times |
|
281 | 281 | |
|
282 |
use "hg -v help add" to show more |
|
|
282 | use "hg -v help add" to show more complete help and the global options | |
|
283 | 283 | |
|
284 | 284 | Verbose help for add |
|
285 | 285 | |
@@ -397,7 +397,7 b' Test command without options' | |||
|
397 | 397 | |
|
398 | 398 | Returns 0 on success, 1 if errors are encountered. |
|
399 | 399 | |
|
400 |
use "hg -v help verify" to show |
|
|
400 | use "hg -v help verify" to show the global options | |
|
401 | 401 | |
|
402 | 402 | $ hg help diff |
|
403 | 403 | hg diff [OPTION]... ([-c REV] | [-r REV1 [-r REV2]]) [FILE]... |
@@ -450,7 +450,7 b' Test command without options' | |||
|
450 | 450 | |
|
451 | 451 | [+] marked option can be specified multiple times |
|
452 | 452 | |
|
453 |
use "hg -v help diff" to show more |
|
|
453 | use "hg -v help diff" to show more complete help and the global options | |
|
454 | 454 | |
|
455 | 455 | $ hg help status |
|
456 | 456 | hg status [OPTION]... [FILE]... |
@@ -513,7 +513,7 b' Test command without options' | |||
|
513 | 513 | |
|
514 | 514 | [+] marked option can be specified multiple times |
|
515 | 515 | |
|
516 |
use "hg -v help status" to show more |
|
|
516 | use "hg -v help status" to show more complete help and the global options | |
|
517 | 517 | |
|
518 | 518 | $ hg -q help status |
|
519 | 519 | hg status [OPTION]... [FILE]... |
@@ -599,7 +599,7 b' Test command with no help text' | |||
|
599 | 599 | |
|
600 | 600 | (no help text available) |
|
601 | 601 | |
|
602 |
use "hg -v help nohelp" to show |
|
|
602 | use "hg -v help nohelp" to show the global options | |
|
603 | 603 | |
|
604 | 604 | $ hg help -k nohelp |
|
605 | 605 | Commands: |
@@ -805,6 +805,75 b' Test keyword search help' | |||
|
805 | 805 | |
|
806 | 806 | qclone clone main and patch repository at same time |
|
807 | 807 | |
|
808 | Test omit indicating for help | |
|
809 | ||
|
810 | $ cat > addverboseitems.py <<EOF | |
|
811 | > '''extension to test omit indicating. | |
|
812 | > | |
|
813 | > This paragraph is never omitted (for extension) | |
|
814 | > | |
|
815 | > .. container:: verbose | |
|
816 | > | |
|
817 | > This paragraph is omitted, | |
|
818 | > if :hg:\`help\` is invoked witout \`\`-v\`\` (for extension) | |
|
819 | > | |
|
820 | > This paragraph is never omitted, too (for extension) | |
|
821 | > ''' | |
|
822 | > | |
|
823 | > from mercurial import help, commands | |
|
824 | > testtopic = """This paragraph is never omitted (for topic). | |
|
825 | > | |
|
826 | > .. container:: verbose | |
|
827 | > | |
|
828 | > This paragraph is omitted, | |
|
829 | > if :hg:\`help\` is invoked witout \`\`-v\`\` (for topic) | |
|
830 | > | |
|
831 | > This paragraph is never omitted, too (for topic) | |
|
832 | > """ | |
|
833 | > def extsetup(ui): | |
|
834 | > help.helptable.append((["topic-containing-verbose"], | |
|
835 | > "This is the topic to test omit indicating.", | |
|
836 | > lambda : testtopic)) | |
|
837 | > EOF | |
|
838 | $ echo '[extensions]' >> $HGRCPATH | |
|
839 | $ echo "addverboseitems = `pwd`/addverboseitems.py" >> $HGRCPATH | |
|
840 | $ hg help addverboseitems | |
|
841 | addverboseitems extension - extension to test omit indicating. | |
|
842 | ||
|
843 | This paragraph is never omitted (for extension) | |
|
844 | ||
|
845 | This paragraph is never omitted, too (for extension) | |
|
846 | ||
|
847 | use "hg help -v addverboseitems" to show more complete help | |
|
848 | ||
|
849 | no commands defined | |
|
850 | $ hg help -v addverboseitems | |
|
851 | addverboseitems extension - extension to test omit indicating. | |
|
852 | ||
|
853 | This paragraph is never omitted (for extension) | |
|
854 | ||
|
855 | This paragraph is omitted, if "hg help" is invoked witout "-v" (for extension) | |
|
856 | ||
|
857 | This paragraph is never omitted, too (for extension) | |
|
858 | ||
|
859 | no commands defined | |
|
860 | $ hg help topic-containing-verbose | |
|
861 | This is the topic to test omit indicating. | |
|
862 | ||
|
863 | This paragraph is never omitted (for topic). | |
|
864 | ||
|
865 | This paragraph is never omitted, too (for topic) | |
|
866 | ||
|
867 | use "hg help -v topic-containing-verbose" to show more complete help | |
|
868 | $ hg help -v topic-containing-verbose | |
|
869 | This is the topic to test omit indicating. | |
|
870 | ||
|
871 | This paragraph is never omitted (for topic). | |
|
872 | ||
|
873 | This paragraph is omitted, if "hg help" is invoked witout "-v" (for topic) | |
|
874 | ||
|
875 | This paragraph is never omitted, too (for topic) | |
|
876 | ||
|
808 | 877 | Test usage of section marks in help documents |
|
809 | 878 | |
|
810 | 879 | $ cd "$TESTDIR"/../doc |
@@ -46,7 +46,7 b' help qrefresh (no record)' | |||
|
46 | 46 | |
|
47 | 47 | [+] marked option can be specified multiple times |
|
48 | 48 | |
|
49 |
use "hg -v help qrefresh" to show |
|
|
49 | use "hg -v help qrefresh" to show the global options | |
|
50 | 50 | |
|
51 | 51 | help qrefresh (record) |
|
52 | 52 | |
@@ -91,7 +91,7 b' help qrefresh (record)' | |||
|
91 | 91 | |
|
92 | 92 | [+] marked option can be specified multiple times |
|
93 | 93 | |
|
94 |
use "hg -v help qrefresh" to show |
|
|
94 | use "hg -v help qrefresh" to show the global options | |
|
95 | 95 | |
|
96 | 96 | $ hg init a |
|
97 | 97 | $ cd a |
@@ -74,7 +74,7 b' help record (record)' | |||
|
74 | 74 | |
|
75 | 75 | [+] marked option can be specified multiple times |
|
76 | 76 | |
|
77 |
use "hg -v help record" to show |
|
|
77 | use "hg -v help record" to show the global options | |
|
78 | 78 | |
|
79 | 79 | help (no mq, so no qrecord) |
|
80 | 80 | |
@@ -85,7 +85,7 b' help (no mq, so no qrecord)' | |||
|
85 | 85 | |
|
86 | 86 | See "hg help qnew" & "hg help record" for more information and usage. |
|
87 | 87 | |
|
88 |
use "hg -v help qrecord" to show |
|
|
88 | use "hg -v help qrecord" to show the global options | |
|
89 | 89 | |
|
90 | 90 | $ hg init a |
|
91 | 91 | |
@@ -117,7 +117,7 b' help (bad mq)' | |||
|
117 | 117 | |
|
118 | 118 | See "hg help qnew" & "hg help record" for more information and usage. |
|
119 | 119 | |
|
120 |
use "hg -v help qrecord" to show |
|
|
120 | use "hg -v help qrecord" to show the global options | |
|
121 | 121 | |
|
122 | 122 | help (mq present) |
|
123 | 123 | |
@@ -150,7 +150,7 b' help (mq present)' | |||
|
150 | 150 | |
|
151 | 151 | [+] marked option can be specified multiple times |
|
152 | 152 | |
|
153 |
use "hg -v help qrecord" to show |
|
|
153 | use "hg -v help qrecord" to show the global options | |
|
154 | 154 | |
|
155 | 155 | $ cd a |
|
156 | 156 |
General Comments 0
You need to be logged in to leave comments.
Login now