teachbooks.release module¶
Teachbooks release workflow.
- teachbooks.release.clean_yaml(path_source: str | Path, path_output: str | Path) None¶
Removes marked sections from a yaml file.
- A marked section can be:
# <START|END> REMOVE-FROM-PUBLISHor
# <START|END> REMOVE-FROM-RELEASE
Does not require a specific indentation and can be used an unlimited number of times in the
*.ymlfile. Commonly applied to_toc.ymland_config.ymlfiles of a book.Example
To remove sub_page_2 and sub_page_3 from publishing:
- file: subdirectory_1/intro_page sections: - file: subdirectory_1/sub_page_1 # START REMOVE-FROM-PUBLISH - file: subdirectory_1/sub_page_2 # END REMOVE-FROM-PUBLISH # START REMOVE-FROM-RELEASE - file: subdirectory_1/sub_page_3 # END REMOVE-FROM-RELEASE - file: subdirectory_2/intro_page
- teachbooks.release.copy_ext(sourcedir: Path) None¶
Copy _ext/ to support APA in release [TEMPORARY].
- teachbooks.release.make_release(sourcedir: Path) tuple[Path, Path]¶
Pre-process files in a Jupyter Book directory.