Description
Problem
There are many cases when a user would want to access file outside of their notebook-dir. For example, @krassowski has created a workaround to allow for symlinks to open python paths in LSP (lsp installation, more info). In other cases, a user may want to open a notebook that lives out of their notebook-dir (e.g. in a shared directory). Today the best option is again to symlink.
We should allow for users allow for one more more directories to be accessible outside of the notebook root directory. For example, I may set --notebook-dir=~/jupyter
and then set the new flag --allowed-dirs=/
to allow for any file to be opened in my OS.
Proposed Solution
Add a traitlet which allows users to configure additional directories to allow Jupyter to open. In my usecase above I would set allowed-dirs
to a parent of my notebook-dir, so this could be as simple as setting --notebook-dir
to /
and defaulting the file browser to open to ~/jupyter
, but I suspect others would want something more general.