mercurial/help.py
changeset 9295 b0f447a259ab
parent 9294 5f4862a00697
child 9298 8a254bd61224
equal deleted inserted replaced
9294:5f4862a00697 9295:b0f447a259ab
    41 
    41 
    42 def listexts(header, exts, maxlength):
    42 def listexts(header, exts, maxlength):
    43     '''return a text listing of the given extensions'''
    43     '''return a text listing of the given extensions'''
    44     if not exts:
    44     if not exts:
    45         return ''
    45         return ''
    46     # TODO: literal block is wrong, should be a field list or a simple table.
    46     result = '\n%s\n\n' % header
    47     result = '\n%s\n\n ::\n\n' % header
       
    48     for name, desc in sorted(exts.iteritems()):
    47     for name, desc in sorted(exts.iteritems()):
    49         desc = util.wrap(desc, maxlength + 5)
    48         result += ' %-*s %s\n' % (maxlength + 2, ':%s:' % name, desc)
    50         result += '  %s   %s\n' % (name.ljust(maxlength), desc)
       
    51     return result
    49     return result
    52 
    50 
    53 def extshelp():
    51 def extshelp():
    54     doc = _(r'''
    52     doc = _(r'''
    55     Mercurial has the ability to add new features through the use of
    53     Mercurial has the ability to add new features through the use of