equal
deleted
inserted
replaced
334 # description |
334 # description |
335 doc = gettext(entry[0].__doc__) |
335 doc = gettext(entry[0].__doc__) |
336 if not doc: |
336 if not doc: |
337 doc = _("(no help text available)") |
337 doc = _("(no help text available)") |
338 if util.safehasattr(entry[0], 'definition'): # aliased command |
338 if util.safehasattr(entry[0], 'definition'): # aliased command |
|
339 source = entry[0].source |
339 if entry[0].definition.startswith('!'): # shell alias |
340 if entry[0].definition.startswith('!'): # shell alias |
340 doc = _('shell alias for::\n\n %s') % entry[0].definition[1:] |
341 doc = (_('shell alias for::\n\n %s\n\ndefined by: %s\n') % |
|
342 (entry[0].definition[1:], source)) |
341 else: |
343 else: |
342 doc = _('alias for: hg %s\n\n%s') % (entry[0].definition, doc) |
344 doc = (_('alias for: hg %s\n\n%s\n\ndefined by: %s\n') % |
|
345 (entry[0].definition, doc, source)) |
343 doc = doc.splitlines(True) |
346 doc = doc.splitlines(True) |
344 if ui.quiet or not full: |
347 if ui.quiet or not full: |
345 rst.append(doc[0]) |
348 rst.append(doc[0]) |
346 else: |
349 else: |
347 rst.extend(doc) |
350 rst.extend(doc) |