Sphinx extension to allow .toc file to builde the Table of Contents
Project description
sphinxcontrib-toc is a Sphinx extension to allow .toc file to build the Table of Contents.
This extension empower you to build complicated document with markup languages which can not define toctrees. Specifically, combination with recommonmark, you don’t need to write any reStructuredText in your document!
Usage
Append this extension in conf.py:
extensions = ['sphinxcontrib.toc']
And configure following settings:
- toc_title
The default title of toctree if no titles in .toc file. By default, "{project} Documentation".
- toc_numbered
Same as :numbered: option of toctree directive. If enabled, Sphinx assigns section numbers. By default, true.
.toc file
.toc file is a list of documents like toctree directive:
section1 section2 section3
You may define the title of toctree at top of the file:
# The title of document section1 section2 section3
Tips
You can use “nested” .toc file like following:
/index.toc /part1.rst /part2.rst /part3/index.toc /part3/section1.toc /part3/section2.toc # In /index.toc part1 part2 part3/index # In /part3/index.toc section1 section2
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file sphinxcontrib-toc-0.9.0.tar.gz
.
File metadata
- Download URL: sphinxcontrib-toc-0.9.0.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 68375c0d50dcdd36c5120f2e4b4bf697dc919542d0ff9eef736238c08ce6eec4 |
|
MD5 | a0dba721feba66edc90b4513b5a8078d |
|
BLAKE2b-256 | 5987ade4bae09c500a6d0d16e43c980ef6ffeb6aa5828ae9ae15d8822fce257c |
File details
Details for the file sphinxcontrib_toc-0.9.0-py2.py3-none-any.whl
.
File metadata
- Download URL: sphinxcontrib_toc-0.9.0-py2.py3-none-any.whl
- Upload date:
- Size: 5.2 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8e9a98f1d139bf2dc56a955f515bd20d77c639b9fd57914e3d226bdf7d2bbb51 |
|
MD5 | 1fe60615ae3f64d4ba8cfdc1e9580423 |
|
BLAKE2b-256 | 832e090c0be774098b52d3fb26b2bef1224e1b6f0fd7db68463ce552bf328ab2 |