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

Allow passing "-" as a file to jupyter workspaces import #6276

Merged
merged 1 commit into from Apr 29, 2019

Conversation

@wonsjb
Copy link
Contributor

@wonsjb wonsjb commented Apr 29, 2019

References

#6272

Code changes

Check for "-" as a file name, and use stdin instead

User-facing changes

User will be able to pass - to mean that they want to load from stdin instead of a file
From:
jupyter lab workspaces import ./workspace.json

To:
cat workspace.json | jupyter lab workspaces import -- -

Note: the -- is necessary to tell the jupyter lab command tool to not take - as a parameter.

Backwards-incompatible changes

None

@jupyterlab-dev-mode
Copy link

@jupyterlab-dev-mode jupyterlab-dev-mode bot commented Apr 29, 2019

Thanks for making a pull request to JupyterLab!

To try out this branch on binder, follow this link: Binder

Copy link
Member

@blink1073 blink1073 left a comment

Wow, that was fast! Thank you @wonsjb!

@afshin afshin added this to the 1.0 milestone Apr 29, 2019
@afshin afshin changed the title Issue-6272 Allow passing "-" as a file to jupyter workspaces import Allow passing "-" as a file to jupyter workspaces import Apr 29, 2019
@afshin
Copy link
Member

@afshin afshin commented Apr 29, 2019

Nice. I just ran this PR in the binder link above and ran this command:

jupyter lab workspaces export | jupyter lab workspaces import -- -

Screen Shot 2019-04-29 at 4 11 56 PM

@blink1073
Copy link
Member

@blink1073 blink1073 commented Apr 29, 2019

Thanks again and congrats on your first contribution to Jupyterlab, @wonsjb!

@blink1073 blink1073 merged commit 0af6067 into jupyterlab:master Apr 29, 2019
9 checks passed
@wonsjb
Copy link
Contributor Author

@wonsjb wonsjb commented Apr 29, 2019

@blink1073 Thank you for the quick approval!

I'm just glad I could help!

JB

@wonsjb wonsjb deleted the ISSUE-6272 branch Apr 29, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Aug 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants