in Guides

Building Visual Studio Code for the Raspberry Pi 3

If you’d rather prefer to use Visual Studio Code for C# development instead of MonoDevelop, you can build Microsoft’s own Visual Studio Code from the source repository. I’ve used Visual Studio Code on Ubuntu and it’s actually a pretty neat tool for developing on Linux. It supports over 30 languages including C#, C++, Python, Java and more, so even if you’re not writing C# code, it’s still a useful tool.

Prerequisites for the build on Linux include Python 2.7, make and libx11-dev which should already be installed on your Pi if you started of with a Raspbian Jessie image. Also, if git has not been installed yet, run sudo apt-get install git. Nodejs and npm also need to be installed, as they will be used by the build script to retrieve some required packages. A recent version of nodejs has to be downloaded since the package version in the repository is not adequate.

Install required dependencies for running Visual Studio Code.

Let’s clone the repository and start the build process.

If you get an error like so:

edit npm-shrinkwrap.json and delete the following lines.

Once the build is completed, you can run:

The script will download a few more required files and perform a few initialisation steps before the IDE launches. The editor performance was very poor when I ran it using X11 forwarding however. Perhaps, it works better if running within a native X11 display.

Visual Studio Code running on the Raspberry Pi 3 using X11 forwarding

Visual Studio Code running on the Raspberry Pi 3 using X11 forwarding

0

Write a Comment

Comment