Mercurial > public > mercurial-scm > hg
comparison mercurial/commands.py @ 23122:d9e3f5055772 stable
help: don't crash on help for 'sections' with multiple '.'
author | Mads Kiilerich <madski@unity3d.com> |
---|---|
date | Sat, 01 Nov 2014 19:02:31 +0100 |
parents | 0b7853f969ac |
children | c26b7a810749 |
comparison
equal
deleted
inserted
replaced
23121:7a3f715dfa90 | 23122:d9e3f5055772 |
---|---|
3835 keep.append('unix') | 3835 keep.append('unix') |
3836 keep.append(sys.platform.lower()) | 3836 keep.append(sys.platform.lower()) |
3837 | 3837 |
3838 section = None | 3838 section = None |
3839 if name and '.' in name: | 3839 if name and '.' in name: |
3840 name, section = name.split('.') | 3840 name, section = name.split('.', 1) |
3841 | 3841 |
3842 text = help.help_(ui, name, **opts) | 3842 text = help.help_(ui, name, **opts) |
3843 | 3843 |
3844 formatted, pruned = minirst.format(text, textwidth, keep=keep, | 3844 formatted, pruned = minirst.format(text, textwidth, keep=keep, |
3845 section=section) | 3845 section=section) |