Add TOC to installation instructions
This adds a Table of Contents to the installation instructions to improve the navigation within the document. I decided to use the command line to configure the TOC because there were problems with using just using an attribute entry in the document header. Specifically the insertion of the `header.asciidoc` into the resulting HTML file prevented the attribute entry approach from working. The TOC can now be inserted into any doc file using toc::[]
This commit is contained in:
parent
a48ea597d0
commit
abd3333b9f
@ -1,6 +1,8 @@
|
|||||||
Installing qutebrowser
|
Installing qutebrowser
|
||||||
======================
|
======================
|
||||||
|
|
||||||
|
toc::[]
|
||||||
|
|
||||||
On Debian / Ubuntu
|
On Debian / Ubuntu
|
||||||
------------------
|
------------------
|
||||||
|
|
||||||
|
@ -184,7 +184,7 @@ class AsciiDoc:
|
|||||||
with open(modified_src, 'w+', encoding='utf-8') as final_version:
|
with open(modified_src, 'w+', encoding='utf-8') as final_version:
|
||||||
final_version.write(title + "\n\n" + header + current_lines)
|
final_version.write(title + "\n\n" + header + current_lines)
|
||||||
|
|
||||||
self.call(modified_src, dst, '--theme=qute')
|
self.call(modified_src, dst, '--theme=qute', '-a toc', '-a toc-placement=manual')
|
||||||
|
|
||||||
def _build_website(self):
|
def _build_website(self):
|
||||||
"""Prepare and build the website."""
|
"""Prepare and build the website."""
|
||||||
|
Loading…
Reference in New Issue
Block a user