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

Feature request: devbox shell -p somepackage #50

Closed
robrich opened this issue Sep 1, 2022 · 3 comments
Closed

Feature request: devbox shell -p somepackage #50

robrich opened this issue Sep 1, 2022 · 3 comments
Labels
feature New feature or request

Comments

@robrich
Copy link
Contributor

robrich commented Sep 1, 2022

It makes it feel a lot like npx. Nothing to install or configure, I just run an isolated command and get results.

@morey-tech
Copy link

morey-tech commented Sep 6, 2022

Thoughts on if something like devbox run <package> could be a better syntax? It follows that of docker. The run signifies that devbox will execute the isolated command and exit. As opposed to shell, which given its current function, could imply that it will stay active after the command has been completed (i.e., a way to install a package in a shell without defining it in the config).

@robrich robrich added the feature New feature or request label Sep 6, 2022
@Lagoja
Copy link
Contributor

Lagoja commented Sep 8, 2022

We're not totally set on how the CLI will do it, but we are looking into devbox run like functionality for an upcoming release. See #94 for more details and discussion

@Lagoja
Copy link
Contributor

Lagoja commented Sep 29, 2022

This is now available in Devbox 0.0.7! You can run a one off command in your devbox shell using:

devbox shell -- <cmd>

This will launch a shell based on your devbox.json, run your command, and then exit back to your normal shell. For example:

~ $  devbox shell -- echo "Hello World"
Installing nix packages. This may take a while...
Starting a devbox shell...
Hello World
~ $ 

More info is in our new CLI Docs: https://www.jetpack.io/devbox/docs/cli_reference/devbox_shell/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Development

No branches or pull requests

3 participants