How to install VS Code on Ubuntu

url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url url

When it comes to app development, you've probably heard of Visual Studio Code. Often referred to by its shorthand VS Code, this is a popular code editor used on Windows and even macOS. However, if you're using one of the many great laptops running Ubuntu Linux or an Ubuntu desktop, you should be happy to know that you can run VS Code on your system. You can install it as a Snap package, as an Apt, or even via the Ubuntu Software Center or through a manual download. We'll look at all three methods for you here.




How to install VS Code on Ubuntu via Software Center

The easiest way to install VS Code on Ubuntu is through the Software Center. It's similar to the Microsoft Store on Windows or the app stores for iOS and Android. You don't have to dig around in the terminal or take any extra steps. Just click a few buttons and you're ready to use the app.

  1. Start Ubuntu search using the Start button on your keyboard.
  2. Search for Ubuntu software.
  3. Click on the top result and start the app.
  4. In the search bar at the top left, search for VScode.
    VS Code in the Ubuntu Software Center

  5. Click on the top result for code.
  6. Click on the Install Button.
  7. Enter your password when prompted.
    VSCode in the Ubuntu Software Center

  8. To install, follow the steps on your screen.


If you have trouble finding VS Code through the Software Center, you can also download it manually. Just visit the Visual Studio Code website and click Download .DEB. Once the file is downloaded, double-click it to launch it and press the green Install Button.

Related

How to install VMWare Tools on Ubuntu

After installing Ubuntu in any VMWare product such as Fusion, Workstation or Player, you need VMWare Tools to manage the operating system.

How to install VS Code as a Snap package

If you prefer to install VS Code as a Snap package for easier management and easier self-management, all you need to do is run the following commands. Remember that you need to press Input after each command.

  1. Start a terminal session.
  2. Install VS Code:
    sudo snap install --classic code
    Installing VS Code on Ubuntu

  3. Enter your password.
  4. Allow the app to download
  5. Once the download is complete, you can search for VS Code using the following command:
    code --version


How to install VS Code with apt

Finally, there is the most difficult method of all to install VS Code. This is intended for more technical users who are comfortable with the terminal and advanced boilerplate. Here's how to do it.

  1. Start a terminal session.
  2. Update your repository:
    sudo apt update
    Updating repositories in Ubuntu

  3. Enter your password.
  4. Install wget and gpg:
    sudo apt-get install wget gpg
  5. Install the dependencies for VS Code:
    wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg
    Installing VS Code using a command line in Ubuntu

  1. Enter your password.
  2. Install the package:
    sudo install -D -o root -g root -m 644 packages.microsoft.gpg /etc/apt/keyrings/packages.microsoft.gpg
  3. Enter your password.
  4. Run the command:
    sudo sh -c 'echo "deb [arch=amd64,arm64,armhf signed-by=/etc/apt/keyrings/packages.microsoft.gpg] https://packages.microsoft.com/repos/code stable main" > /etc/apt/sources.list.d/vscode.list'
  5. Enter your password.
  6. Run the command:
    rm -f packages.microsoft.gpg
  7. Run the command:
    sudo apt install apt-transport-https -y
    Installing VS Code using the Terminal in Ubuntu

  8. Run the command:
    sudo apt install code


Once you have completed the above steps, you can verify the installation with Code – Version.

That's it! You should now have VS Code installed on Ubuntu. We also recommend installing other developer tools like MySQL or Java. If you decide to remove the app, the steps are different for each installation method. If you installed the app via the Software Center, visit the Furnished the app and click Uninstall. If you installed with Snap, use the command sudo snap Remove code. If you installed with apt, use the command sudo apt Remove code.

Leave a Comment