Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copy executable docs listed in _toc.yml over to /files #48

Open
psychemedia opened this issue May 4, 2022 · 2 comments
Open

Copy executable docs listed in _toc.yml over to /files #48

psychemedia opened this issue May 4, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@psychemedia
Copy link

The demo executable-book PR executablebooks/sphinx-book-theme#558 adds a "Launch in Jupterlite" button to Jupyter Book.

At the moment, the user must manually copy over notebook files to the distribution.

Ideally,jupyterlite-sphinx should copy over executable documents (that can be legitimately launched in JupyterLite) that are listed in _toc.yml over to the distribution directory (eg _build/html/lite/files). There also needs to be a mechanism to copy over additional files referenced from the notebooks.

I'm a little wary that a blanket "copy over all the contents of a specified directory" is too heavyweight, and might copy over unpublished book files that are not listed in _toc.yml over to the JupyterLite file tree.

@psychemedia psychemedia added the enhancement New feature or request label May 4, 2022
@psychemedia
Copy link
Author

psychemedia commented Jun 27, 2022

PR 944ccf4 seems to support a jupyterlite_contents setting in conf.py that will copy path contents over to the distribution.

It might perhaps be handy to be able to ignore specified files in that directory too?

@psychemedia
Copy link
Author

psychemedia commented Aug 22, 2022

Contents can be copied over to files based on glob pattern matching in 6730bef . Would it also make sense to see if the match pattern is actually a file path, eg to a _toc.yml type file, and use that as basis for copying over files?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant