equal
deleted
inserted
replaced
1246 node=ctx.hex(), changenav=changenav) |
1246 node=ctx.hex(), changenav=changenav) |
1247 |
1247 |
1248 def _getdoc(e): |
1248 def _getdoc(e): |
1249 doc = e[0].__doc__ |
1249 doc = e[0].__doc__ |
1250 if doc: |
1250 if doc: |
1251 doc = _(doc).split('\n')[0] |
1251 doc = _(doc).partition('\n')[0] |
1252 else: |
1252 else: |
1253 doc = _('(no help text available)') |
1253 doc = _('(no help text available)') |
1254 return doc |
1254 return doc |
1255 |
1255 |
1256 @webcommand('help') |
1256 @webcommand('help') |
1276 def topics(**map): |
1276 def topics(**map): |
1277 for entries, summary, _doc in helpmod.helptable: |
1277 for entries, summary, _doc in helpmod.helptable: |
1278 yield {'topic': entries[0], 'summary': summary} |
1278 yield {'topic': entries[0], 'summary': summary} |
1279 |
1279 |
1280 early, other = [], [] |
1280 early, other = [], [] |
1281 primary = lambda s: s.split('|')[0] |
1281 primary = lambda s: s.partition('|')[0] |
1282 for c, e in commands.table.iteritems(): |
1282 for c, e in commands.table.iteritems(): |
1283 doc = _getdoc(e) |
1283 doc = _getdoc(e) |
1284 if 'DEPRECATED' in doc or c.startswith('debug'): |
1284 if 'DEPRECATED' in doc or c.startswith('debug'): |
1285 continue |
1285 continue |
1286 cmd = primary(c) |
1286 cmd = primary(c) |