git.iko.soy/typeable/pandoc
on master help sign in
Support --number-sections in RST output...

via the "section-numbering" directive in standalone output.

commit6ea706256de67c5480b300b0063729ae8f459c4c authorJohn MacFarlane <jgm@berkeley.edu> dateSat 2 Jun 2018, 21:37 (8 years ago) parentd32e866
2 files changed+5
data/templates/default.rst+4 src/Text/Pandoc/Writers/RST.hs+1
data/templates/default.rst+4
@@ -30,6 +30,10 @@ $if(toc)$
3030 :depth: $toc-depth$
3131..
3232
33+$endif$
34+$if(number-sections)$
35+.. section-numbering::
36+
3337$endif$
3438$for(header-includes)$
3539$header-includes$
src/Text/Pandoc/Writers/RST.hs+1
@@ -103,6 +103,7 @@ pandocToRST (Pandoc meta blocks) = do
103103 let context = defField "body" main
104104 $ defField "toc" (writerTableOfContents opts)
105105 $ defField "toc-depth" (show $ writerTOCDepth opts)
106+ $ defField "number-sections" (writerNumberSections opts)
106107 $ defField "math" hasMath
107108 $ defField "title" (render Nothing title :: String)
108109 $ defField "math" hasMath