Skip to content
This repository has been archived by the owner on Nov 28, 2019. It is now read-only.

Add paramnb support for Foldername parameters #41

Open
thoth291 opened this issue Apr 12, 2017 · 1 comment
Open

Add paramnb support for Foldername parameters #41

thoth291 opened this issue Apr 12, 2017 · 1 comment

Comments

@thoth291
Copy link

In one of my current projects I'm trying to wrap a shell script generation into paramnb widget.
That requires define a folder for input data.
Currently I'm doing to like this:
image
using this code:

multiple_files = param.MultiFileSelector(path='*')

The problem is that I don't know how to check if selected PYTHON is a folder or a file.
Is there any way to make some validation of selection or restrict the globbing to show only directories?

Thanks in Advance!

@jbednar jbednar changed the title Directory Selector tool Add paramnb support for Foldername parameters Apr 12, 2017
@jbednar
Copy link
Member

jbednar commented Apr 12, 2017

This would be a case where you'd use the Foldername parameter, which only allows folders as values. However, when you do, you'll see that ParamNB does not currently do anything special for Foldername parameters (only a textbox), so ParamNB will need to be extended to add support for exposing the correct ipywidget for this case. We'll do that eventually, but probably not soon, and meanwhile we'd be happy to accept a PR for it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants