You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ nbinteract --gitbook foo.ipynb bar.ipynb
# converts all notebooks in folder and outputs to notebooks-html/
$ nbinteract --gitbook --output notebooks-html notebooks/
# converts all notebooks in folder, outputs to notebooks-html/,# and outputs images to notebooks-images/
$ nbinteract --gitbook --output notebooks-html --images notebook-images notebooks/
# converts all notebooks in folder and recurses into all subfolders
$ nbinteract --gitbook -r notebooks/
# converts all notebooks in folder and recurses into all subfolders,# then outputs notebooks into notebooks-html without folders
$ nbinteract --gitbook --output notebooks-html -r notebooks/
Here's a docopt docstring that I think might work:
'''Converts notebooks to interactive HTML pages or Gitbook pages.Usage: nbinteract NOTEBOOKS...Arguments: NOTEBOOKS The list of notebooks or folders containing notebooks to convert.Options: -g --gitbook Convert to HTML partial for Gitbook -r --recursive Recursively convert notebooks in subdirectories. Leaves HTML files in the same folders as the original notebooks. -o FOLDER --output=FOLDER Outputs HTML files into FOLDER. If -r is also set, will not recreate input folder structure in output folder (all output files are direct children of FOLDER). -i FOLDER --images=FOLDER Extracts images from HTML and writes into FOLDER. Requires -o option to be set as well.'''
I'd like to replace all the
convert_notebooks_to_html_partial.py
files we have across these textbooks:With something like:
Here's a
docopt
docstring that I think might work:Right now we have the following CLI option:
Which is a simple alias of
We'll have to change the script to use Python instead of bash.
The text was updated successfully, but these errors were encountered: