ipypublish.scripts.nbmerge module¶
usage:
python nbmerge.py directory_name > merged.ipynb
-
ipypublish.scripts.nbmerge.
alphanumeric_sort
(l)[source]¶ sort key.name alphanumerically
Parameters: l (list[str]) –
-
ipypublish.scripts.nbmerge.
merge_notebooks
(ipynb_path, ignore_prefix='_', to_str=False, as_version=4)[source]¶ merge one or more ipynb’s, if more than one, then the meta data is taken from the first
Parameters: - ipynb_path (str or pathlib.Path) –
- ignore_prefix (str) – ignore filename starting with this prefix
- to_str (bool) – return as a string, else return nbformat object
- as_version (int) – notebook format vesion
Returns: - finalnb (jupyter.notebook)
- meta_path (pathlib.Path) – path to notebook containing meta file