This guide assumes you already have WSL installed in your system and you are currenly running an Ubuntu distro.
1. Get XFCE ready
If you are new to running WSL on Windows, we recommend you to follow our Guide to Run XFCE in Windows 10 via WSL.
Once XFCE is installed run VcXserv in your Windows side, open an Ubuntu Bash and run
xfce4-session. XFCE4 isn’t a requirement as you can use other Window Managers in WSL, but that will be a topic for another post.
We recommend running VcXserv as a single window mode as it will allow you to see the Linux Desktop and we find that it’s the best experience for WSL at the moment.
At this point you should see an XFCE desktop enviroment. From there you can run bundled apps like Settings, File Manager and others. If everything works well at this point, you are ready to install Visual Studio Code.
2. Add VSCode repository
Add the repository as explained in the official VS Code Linux page. Once added your system will be able to install both
code-insiders as well as keeping them up to date via
curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg
3. Install VSCode Insiders (or just Code)
sudo apt install code-insiders
After the installation is complete, you can go to your Applications menu and find Visual Studio Code (or Visual Studio Code Insiders) under the Development tab.
4. Run VSCode
If everything goes well you should see Code loading and working as expected.
- New Features in WSL2 for Windows 10
WSL2 is coming to Windows 10. Discover the new features.