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

✨ Open VSCode & run command in terminal via code cli #190142

Closed
jd-solanki opened this issue Aug 10, 2023 · 1 comment
Closed

✨ Open VSCode & run command in terminal via code cli #190142

jd-solanki opened this issue Aug 10, 2023 · 1 comment
Assignees
Labels
*duplicate Issue identified as a duplicate of another issue(s)

Comments

@jd-solanki
Copy link

Hi πŸ‘‹πŸ»

In most of the cases, when I open VSCode, I would like to run commands like npm install or poetry install to install project dependencies. For example, When I clone the repo via git, I use git clone XXX && code XXX once VSCode is open I had to run npm install or poetry install in terminal.

We can install the dependencies before opening VSCode but it's common that everyone will start the dev server in VSCode and not in the (temporary) terminal. For example:

git clone XXX && cd XXX && npm install && echo "oops! I don't want to start server in this terminal"

It will be much easier if we can provide cli argument to run the specific command in terminal when vscode is opened via code command. Once this is implemented it will easy as below:

git clone XXX && code XXX -e 'npm install && npm run dev'
@Tyriar
Copy link
Member

Tyriar commented Aug 10, 2023

I think we can merge this into #93241 which is essentially asking for a terminal subcommand. We wouldn't implement terminal control without it being sectioned off like that since there are many things a user may want to do with the terminal like Windows Terminal's CLI:

image

You might find automatic tasks useful https://code.visualstudio.com/Docs/editor/tasks#_run-behavior

/duplicate

@Tyriar Tyriar closed this as completed Aug 10, 2023
@VSCodeTriageBot VSCodeTriageBot added the *duplicate Issue identified as a duplicate of another issue(s) label Aug 10, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Sep 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*duplicate Issue identified as a duplicate of another issue(s)
Projects
None yet
Development

No branches or pull requests

3 participants