Skip to content

Add support for copying output files to website #1421

Open
@idahlke-blacksky

Description

@idahlke-blacksky

My notebooks are producing file outputs of various types that need to be available on the final docs page. Currently it appears that nbdev_docs copies the nbs folder to the _proc folder before processing the notebooks. The files I need aren't created until execution time, so they are missed. Concurrently the working directory for execution appears to be the project root, not the notebook location, so all file outputs would be written to the root directory without applying any workarounds. Without workarounds this creates some differences between the local notebook development environment and the nbdev_docs call (when done from the project root).

Generally I work around this by writing everything to ./outputs/... and creating a symlink between project_root/outputs and project_root/nbs/outputs. For now I've also created one to project_root/_proc/outputs. That works but the system is a bit janky. It requires nbdev_docs --symlinks so the default workflows don't work, and the _proc directory cannot be completely cleared.

It would be nice if the working directory were set to the file location by nbdev_docs and furthermore if created files were picked up and moved to _proc after execution was complete.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions