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

Launch with command-line or notebook file double-click #273

Merged
merged 9 commits into from
Oct 7, 2021

Conversation

mbektas
Copy link
Member

@mbektas mbektas commented Oct 3, 2021

  • Adds command-line launch support with command jlab
    • jlab ../relative-dir/another to open directories
    • jlab ../relative-dir/test.ipynb or jlab /absolute-dir/test.py to open files
  • Adds support to open .ipynb files with double click
  • Sets home directory to directory being opened or directory of file being opened

fixes #256, #262, #233

@mbektas mbektas changed the title Launch with command-line or click Launch with command-line or notebook file double-click Oct 3, 2021
@mbektas mbektas marked this pull request as ready for review October 3, 2021 06:50
Copy link
Contributor

@blink1073 blink1073 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, thank you!

@krassowski
Copy link
Member

Should we discuss the name of the command, this is whether this should be jlab, jupyterlab, or something else like more explicit jupyterlab-desktop? I saw users complaining about being confused with the variations on Windows (jupyter lab, jupyter-lab) already. @jasongrout any thoughts?

@blink1073
Copy link
Contributor

👍🏼 for naming the executable jupyterlab-desktop, which the user could alias to something shorter if they want.

@mbektas
Copy link
Member Author

mbektas commented Oct 3, 2021

command name is open for discussion. Here is what my thinking with jlab was: I wanted to have the shortest meaningful name with jlab. It is a name we often use to refer to JupyterLab in conversations. A name like jupyterlab-desktop is more explicit but user needs to type till jupyterl for tab completion to work if they have jupyter command already on the same environment.

@jasongrout
Copy link
Contributor

jasongrout commented Oct 5, 2021

My two cents: I kind of like jlab:

  • Mehmet's right that it is short and sweet. It's nice that it is very functional out of the box.
  • I think it probably shouldn't be jupyter-something, so that it won't conflict with our namespace of for binaries invoked as a jupyter subcommand (like jupyter something). To me, it seems that jupyterlab-desktop is also confusing with jupyter-desktop (if that ever happens).
  • My guess is that those downloading and using this are looking for a prebuilt solution-in-a-box, and aren't looking to immediately alias it to have something more functional.

But I'm also the person advocating for micromamba to be renamed to something like mm on the command line because it's much easier to type (in the end, I made an alias in my .zshrc, so maybe that's a vote in favor of Steve's suggestion, but at the same time, there are probably lots of people wanting to use this easily from the command line that would rather not muck around in config files to create an alias, or figure out how to do an alias on Windows).

Besides, what else do you think we should reserve jlab for? It's a prime name, but this seems like a prime opportunity as well.

@fperez
Copy link

fperez commented Oct 7, 2021

Huge thanks for this work, and 👍 on the jlab option - I agree it's the right opportunity to use it, and in my mind it matches how the cmd-line opener for VSCode is just code, also short and sweet (not some Visual Studio Code monstrosity that would require all kinds of escaping.

At the shell, every keystroke matters ⌨️ :)

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

Successfully merging this pull request may close these issues.

Open currrent folder from command line
5 participants