How to Install Visual Studio Code on Ubuntu 18.04

Install Visual Studio Code on Ubuntu 18.04

In this article, we will have explained the necessary steps to install and configure Visual Studio Code on Ubuntu 18.04 LTS. Before continuing with this tutorial, make sure you are logged in as a user with sudo privileges. All the commands in this tutorial should be run as a non-root user.

Visual Studio Code also known as VS Code is a lightweight IDE developed by Microsoft. Mainly designed for web application development and have built in support popular JavaScript frameworks, also has support for many different programming languages such as PHP, Java, GO, C++, C#, Python and many more.

Install Visual Studio Code on Ubuntu

Step 1. First, before you start installing any package on your Ubuntu server, we always recommend making sure that all system packages are updated.

sudo apt update
sudo apt install software-properties-common apt-transport-https wget
sudo apt upgrade

Step 2. Install Visual Studio Code on Ubuntu.

Now we import the Microsoft GPG key using the following command:

wget -q https://packages.microsoft.com/keys/microsoft.asc -O- | sudo apt-key add -

Next, enable the Visual Studio Code repository:

sudo add-apt-repository "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main"

Then, use the apt command to install Visual Studio Code:

sudo apt update
sudo apt install code

Step 4. Accessing Visual Studio Code.

Once the Visual Studio Code is installed on your system, you can launch it either from the command line or by clicking on the Visual Studio Code icon in graphical mode:

code

That’s all you need to do to install Visual Studio Code on Ubuntu 18.04. I hope you find this quick tip helpful. If you have questions or suggestions, feel free to leave a comment below.