Generate book files from a Table of Contents¶
It is possible to use a
_toc.yml file in order to create the skeleton of a book automatically.
This is useful if you wish to quickly generate empty files from a single structure, and then populate them with content yourselves.
To create your book’s files from the Table of Contents, use the following command:
jupyter-book toc to-project path/to/_toc.yml
This will generate a collection of files according to the structure in
In addition, you have a few options to control the behavior of this tool. See below for reference.
Usage: jupyter-book toc to-project [OPTIONS] TOC_FILE Create a project directory from a ToC file. Options: -p, --path DIRECTORY The root directory [default: ToC file directory]. -e, --extension [rst|md] The default file extension to use. [default: rst] -o, --overwrite Overwrite existing files. -h, --help Show this message and exit.