Table of Contents
Let's get started
Method 1. Install visual studio code from snap
In this section, we will install the visual studio code from the snap package. It is officially available in Snap Package in the snap store.
Enter the following command to install
sudo snap install --classic code # or code-insiders
Once you installed it from the snap package. Snap package daemon will automatically update the install VS code editor.
Method 2. Install using .deb file
In this section, we will install the visual studio code from .deb. Open the following URL and download the latest vs code editor.
Once you download navigate to your download directory and enter the following command
sudo dpkg -i <vs-code-editor-download-file>.deb
The above command will install the vs code editor. Now enter the following command to install its dependency.
sudo apt install -f
Method 3. Install using official Linux repositories
In this section, we can also install the visual studio IDE using Linux repositories all you need to do is add the repo and install. To do so enter the following command to add.
curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg sudo install -o root -g root -m 644 packages.microsoft.gpg /usr/share/keyrings/ sudo sh -c 'echo "deb [arch=amd64 signed-by=/usr/share/keyrings/packages.microsoft.gpg] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list'
Now update your repository cache and install the package using below command
sudo apt-get install apt-transport-https sudo apt-get update sudo apt-get install code # or code-insiders