Show More
@@ -654,9 +654,18 b' def format(text, width=80, indent=0, kee' | |||||
654 | if section: |
|
654 | if section: | |
655 | sections = getsections(blocks) |
|
655 | sections = getsections(blocks) | |
656 | blocks = [] |
|
656 | blocks = [] | |
657 | for name, nest, b in sections: |
|
657 | i = 0 | |
|
658 | while i < len(sections): | |||
|
659 | name, nest, b = sections[i] | |||
658 | if name == section: |
|
660 | if name == section: | |
659 |
blocks |
|
661 | blocks.extend(b) | |
|
662 | ||||
|
663 | ## Also show all subnested sections | |||
|
664 | while i + 1 < len(sections) and sections[i + 1][1] > nest: | |||
|
665 | i += 1 | |||
|
666 | blocks.extend(sections[i][2]) | |||
|
667 | i += 1 | |||
|
668 | ||||
660 | if style == 'html': |
|
669 | if style == 'html': | |
661 | text = formathtml(blocks) |
|
670 | text = formathtml(blocks) | |
662 | else: |
|
671 | else: |
@@ -1061,6 +1061,35 b' Test section lookup' | |||||
1061 | graphical tools such as "hg log --graph". In Mercurial, the DAG is |
|
1061 | graphical tools such as "hg log --graph". In Mercurial, the DAG is | |
1062 | limited by the requirement for children to have at most two parents. |
|
1062 | limited by the requirement for children to have at most two parents. | |
1063 |
|
1063 | |||
|
1064 | ||||
|
1065 | $ hg help hgrc.paths | |||
|
1066 | "paths" | |||
|
1067 | ------- | |||
|
1068 | ||||
|
1069 | Assigns symbolic names to repositories. The left side is the symbolic | |||
|
1070 | name, and the right gives the directory or URL that is the location of the | |||
|
1071 | repository. Default paths can be declared by setting the following | |||
|
1072 | entries. | |||
|
1073 | ||||
|
1074 | "default" | |||
|
1075 | Directory or URL to use when pulling if no source is specified. | |||
|
1076 | Default is set to repository from which the current repository was | |||
|
1077 | cloned. | |||
|
1078 | ||||
|
1079 | "default-push" | |||
|
1080 | Optional. Directory or URL to use when pushing if no destination is | |||
|
1081 | specified. | |||
|
1082 | ||||
|
1083 | Custom paths can be defined by assigning the path to a name that later can | |||
|
1084 | be used from the command line. Example: | |||
|
1085 | ||||
|
1086 | [paths] | |||
|
1087 | my_path = http://example.com/path | |||
|
1088 | ||||
|
1089 | To push to the path defined in "my_path" run the command: | |||
|
1090 | ||||
|
1091 | hg push my_path | |||
|
1092 | ||||
1064 | $ hg help glossary.mcguffin |
|
1093 | $ hg help glossary.mcguffin | |
1065 | abort: help section not found |
|
1094 | abort: help section not found | |
1066 | [255] |
|
1095 | [255] |
General Comments 0
You need to be logged in to leave comments.
Login now