The WSL extension splits VS Code into a “client-server” architecture, with the client (the user interface) running on your Windows machine and the server (your code, Git, plugins, etc) running "remotely" in your WSL distribution. If you then type WSL you will see a list of the options available, allowing you to reopen the folder in a WSL session, specify which distribution you want to open in, and more. You can also access more VS Code WSL options by using the shortcut: CTRL SHIFT P in VS Code to bring up the command palette. To open a project from your WSL distribution, open the distribution's command line and enter: code. Open a WSL project in Visual Studio Code From the command-line To add wget (to retrieve content from web servers) and ca-certificates (to allow SSL-based applications to check for the authenticity of SSL connections), enter: sudo apt-get install wget ca-certificates You can add additional libraries into your Linux distribution by using its package manager.įor example, to update Debian or Ubuntu, use: sudo apt-get update Some WSL Linux distributions are lacking libraries that are required by the VS Code server to start up. Fun fact: this WSL extension is installed in $HOME/.vscode/extensions (enter the command ls $HOME\.vscode\extensions\ in PowerShell). We do not recommend using WSL in VS Code without the WSL extension as you will lose support for auto-complete, debugging, linting, etc. In order to install the WSL extension, you will need the 1.35 May release version or later of VS Code. This extension pack includes the WSL extension, in addition to the Remote - SSH, and Dev Containers extensions, enabling you to open any folder in a container, on a remote machine, or in WSL. Install the Remote Development extension pack. When prompted to Select Additional Tasks during installation, be sure to check the Add to PATH option so you can easily open a folder in WSL using the code command. Install Visual Studio Code on Windows (not in your WSL file system). Visit the VS Code install page and select the 32 or 64 bit installer.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |