2

It is possible to compile Visual Studio Code and install it through terminal as explained here and here. Now I wonder, does anyone know how is it possible to install/add extensions to Visual Studio Code through Terminal?

3

You can get the command line help with

code -h

(A man pages doesn't exist.)

Extensions Management:
  --extensions-dir <dir>                                         Set the root path for extensions.
  --list-extensions                                              List the installed extensions.
  --show-versions                                                Show versions of installed extensions, when
                                                                 using --list-extension.
  --install-extension (<extension-id> | <extension-vsix-path>)   Installs an extension.
  --uninstall-extension (<extension-id> | <extension-vsix-path>) Uninstalls an extension.
  --enable-proposed-api <extension-id>                           Enables proposed API features for an extension.

Hence all you need is the extension-id or extension-vsix-path and then

code --install-extension (<extension-id> | <extension-vsix-path>)

E.g. the ms-python package can be installed by

code --install-extension ms-python.python

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.