##// END OF EJS Templates
minirst: don't treat top level item as children of last item (issue4803)...
timeless@mozdev.org -
r26157:65e41f38 default
parent child Browse files
Show More
@@ -727,6 +727,21 b' def getsections(blocks):'
727 if not secs:
727 if not secs:
728 # add an initial empty section
728 # add an initial empty section
729 secs = [('', 0, [])]
729 secs = [('', 0, [])]
730 if b['type'] != 'margin':
731 pointer = 1
732 bindent = b['indent']
733 while pointer < len(secs):
734 section = secs[-pointer][2][0]
735 if section['type'] != 'margin':
736 sindent = section['indent']
737 if len(section['lines']) > 1:
738 sindent += len(section['lines'][1]) - \
739 len(section['lines'][1].lstrip(' '))
740 if bindent >= sindent:
741 break
742 pointer += 1
743 if pointer > 1:
744 secs.append(('', secs[-pointer][1] + 1, []))
730 secs[-1][2].append(b)
745 secs[-1][2].append(b)
731 return secs
746 return secs
732
747
@@ -922,6 +922,22 b' Test repeated config section name'
922 "smtp.host"
922 "smtp.host"
923 Host name of mail server, e.g. "mail.example.com".
923 Host name of mail server, e.g. "mail.example.com".
924
924
925 Help subsection:
926
927 $ hg help config.charsets |grep "Email example:" > /dev/null
928 [1]
929
930 Last item in help config.*:
931
932 $ hg help config.`hg help config|grep '^ "'| \
933 > tail -1|sed 's![ "]*!!g'`| \
934 > grep "hg help -c config" > /dev/null
935 [1]
936
937 note to use help -c for general hg help config:
938
939 $ hg help config |grep "hg help -c config" > /dev/null
940
925 Test templating help
941 Test templating help
926
942
927 $ hg help templating | egrep '(desc|diffstat|firstline|nonempty) '
943 $ hg help templating | egrep '(desc|diffstat|firstline|nonempty) '
General Comments 0
You need to be logged in to leave comments. Login now