$%TOC_BEGIN$
- 1 What is this?
- 2 How to run?
-
3 License?
$%TOC_END$
This script allows for an easy generation of the table of content inside given markdown file.
It parsed the markdown file, locates all headers and numbers them. Then, it generates the TOC (as seen in the beginning of this README).
The script looks for [TOC]
mark inside the file, which it then replaces with the TOC content.
Just run the script again, the TOC will be updated automatically.
$ ./md-toc-generator.py --help
> Usage: ./md-toc-generator.py file [TOC chapter name]
> The second parameter overrides default TOC_CHAPTER_NAME
MIT.