How to Install Visual Studio Code in Ubuntu 18.04/20.04

How to Install Visual Studio Code in Ubuntu 18.04/20.04

Visual studio code is a source code editor developed by Microsoft for both Linux, Windows, and macOS. It is one of the most popular and powerful text editors used by software engineers in the world today. VS Code is one of the most popular because it is more regularly updated, more customizable, and boasts a more diverse ecosystem of extensions than its competitors.

Here, we are going to learn how to install the Visual Studio Code on your Ubuntu 20.04, look at some of its features and the advantages it has over other text editor applications.

Features of Visual Studio Code

Visual studio code comes with amazing built-in features which include:

  1. Embedded Git- performs several git commands such as commit, rebase, push, pull, publish, and look into the changes within the file.
  2. intelligent code completion,
  3. syntax highlighting,
  4. snippets,
  5. code refactoring,
  6. and embedded Git.
  7. Here, users can also change the keyboard shortcuts, themes and install extensions that add additional functionality to the system.

Advantages of VS Code

  1. decently fast and easy to use.
  2. has incredible dabbed window management that allows grid-based split screen.
  3. has lots of extensions available for different languages which makes code even more versatile.
  4. low resource costs.
  5. fast programming and debugging experience.   
  6. Easy intergration with Git.
  7. Support for multiple programming languages with intelli-sense.             

Installation of Visual Studio Code

To begin the installation, make sure to have a fully updated version of ubuntu 20.04 installed on your machine.

As a root, update the packages index and install the dependencies by running the following command.

# sudo apt update

sudo apt update && sudo apt upgrade -y

Use the below command to install wget tool if you haven’t installed it before.

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

Import the Microsoft GPG key using wget command.

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

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

Now add Visual Studio Code repository in ubuntu.

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

No install visual studio code editor on Ubuntu 20.04

sudo apt install code

Congratulations, the visual studio code has been successfully installed.

When a new version is released, you can update the visual studio code package by running the following commands in your terminal:

   # sudo apt update

   # sudo apt update

Starting visual code studio

Visual studio code is now installed on your ubuntu 20.04, you can launch it by typing code on your terminal or by clicking on the VS Code icon in the activities on your screen.

You should be able to see a screen similar to the screenshot below:

Conclusion

You have successfully installed VS Code on your machine and you can now browse for more exciting features in the application.

Leave a Reply

Your email address will not be published. Required fields are marked *

18 − 3 =