How to install Visual Studio Code on CentOS 8

Visual Studio Code is an open source cross-platform code editor developed by Microsoft. Visual Studio has built-in debugging support, built-in Git controls, syntax highlighting, code completion, integrated terminal, refactoring, and snippets.

The easiest and recommended way to install Visual Studio Code on CentOS 8 is to enable the VS Code repository and install the VS Code package via command line.

This tutorial describes how to install the Visual Studio Code Editor on.

precondition

To install Visual Studio Code on CentOS 8, you must be logged in as a user with sudo privileges.

Install Visual Studio Code on CentOS 8

The easiest and recommended way to install Visual Studio Code on a CentOS 8 system is to enable the VS Code repository and install the VS Code package via the command line:

  1. Microsoft GPG key import:
    sudo rpm --import https://packages.microsoft.com/keys/microsoft.asc
  2. Open a text editor and create a repository file:
    sudo nano /etc/yum.repos.d/vscode.repo

    Copy and paste the following contents to activate the VS Code repository:

    [code]
    name=Visual Studio Code
    baseurl=https://packages.microsoft.com/yumrepos/vscode
    enabled=1
    gpgcheck=1
    gpgkey=https://packages.microsoft.com/keys/microsoft.asc

    Save and close the text editor nano If you are done.

  3. Install the latest version of Visual Studio Code by typing:
    sudo dnf install code

Visual Studio Code is preinstalled on CentOS and you can start using it.

Starting Visual Studio Code in CentOS 8

Now that you have VS Code installed on your CentOS system, you can run it either from the command line by typing code Or by clicking on the VS Code (Applications -> Programming -> Visual Studio Code).

When starting VS Code for the first time, a window like the following will appear:

Centos Visual Studio Code

You can now start installing extensions and configuring VS Code according to your preference.

Update Visual Studio Code on CentOS 8

When a new release is released, you can update Visual Studio Code packages via Software update tool Standard desktop or by running the following command on your terminal:

sudo dnf update

Conclusion

You have successfully installed VS Code on your CentOS 8. The next step is to install plug-ins and customize user and workspace settings.

To learn more about VS Code, visit the official VS Code documentation page.

.

Source link

Leave a Reply

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