Show More
@@ -3249,7 +3249,17 b' def help_(ui, name=None, unknowncmd=Fals' | |||||
3249 | 'global options') % (name and " " + name or "") |
|
3249 | 'global options') % (name and " " + name or "") | |
3250 | optlist.append((msg, ())) |
|
3250 | optlist.append((msg, ())) | |
3251 |
|
3251 | |||
3252 | ui.write(help.opttext(optlist, textwidth, ui.verbose)) |
|
3252 | if not optlist: | |
|
3253 | return | |||
|
3254 | ||||
|
3255 | rst = '' | |||
|
3256 | for title, options in optlist: | |||
|
3257 | rst += '\n%s\n' % title | |||
|
3258 | if options: | |||
|
3259 | rst += "\n" | |||
|
3260 | rst += help.optrst(options, ui.verbose) | |||
|
3261 | rst += '\n' | |||
|
3262 | ui.write('\n' + minirst.format(rst, textwidth)) | |||
3253 |
|
3263 | |||
3254 | def helptopic(name): |
|
3264 | def helptopic(name): | |
3255 | for names, header, doc in help.helptable: |
|
3265 | for names, header, doc in help.helptable: |
@@ -62,21 +62,6 b' def optrst(options, verbose):' | |||||
62 |
|
62 | |||
63 | return ''.join(rst) |
|
63 | return ''.join(rst) | |
64 |
|
64 | |||
65 | # list all option lists |
|
|||
66 | def opttext(optlist, width, verbose): |
|
|||
67 | rst = '' |
|
|||
68 | if not optlist: |
|
|||
69 | return '' |
|
|||
70 |
|
||||
71 | for title, options in optlist: |
|
|||
72 | rst += '\n%s\n' % title |
|
|||
73 | if options: |
|
|||
74 | rst += "\n" |
|
|||
75 | rst += optrst(options, verbose) |
|
|||
76 | rst += '\n' |
|
|||
77 |
|
||||
78 | return '\n' + minirst.format(rst, width) |
|
|||
79 |
|
||||
80 | def topicmatch(kw): |
|
65 | def topicmatch(kw): | |
81 | """Return help topics matching kw. |
|
66 | """Return help topics matching kw. | |
82 |
|
67 |
General Comments 0
You need to be logged in to leave comments.
Login now