How to Install Visual Studio Code in Fedora Linux

Channel: Linux
Abstract: Press ‘y’ for to approve the installation of packages. Step 3 – Launch Visual Studio Code The Visual Studio Code has been installed on your system. Yo

Visual Studio Code (not Visual Studio IDE) is a lightweight source code editor for JavaScript, TypeScript, and Node.js Applications. It also has extensions for multiple other programming languages like C++, C#, Python, PHP, Go, etc. This tutorial will help you to install Visual Studio Code on CentOS, RHEL, Fedora, and its derivatives systems. Remember that Visual Studio Code is a different application than Microsoft Visual Studio IDE.

  • How to Install Visual Studio Code Editor in Ubuntu & Debian
  • How to Install Visual Studio Code Editor in SEL & openSUSE
Step 1 – Enable Yum Repository

Visual Studio Code provides an official yum repository for the installation of packages on a Yum-supported system. The same repository can be used for Fedora systems to use with DNF. Let’s create a new file /etc/yum.repos.d/vscode.repo and edit in your favorite text editor.

sudo nano /etc/yum.repos.d/vscode.repo 

Add the below content:

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

Press CTRL+O to save content and CTRL+X to exit from the editor.

Step 2 – Install Visual Studio Code

DNF package manager will automatically manage the gpg key for you, but you can also Import the package signing GPG key on your system using the following command.

sudo rpm --import https://packages.microsoft.com/keys/microsoft.asc 

After importing the GPG key, Let’s use commands to install Visual Studio Code on your RHEL-based system.

sudo dnf install code 

Press ‘y’ for to approve the installation of packages.

Step 3 – Launch Visual Studio Code

The Visual Studio Code has been installed on your system. You can now launch the Visual Studio Code editor on your system using the desktop menu. After that create a new file or open files and directories using the File menu.

Step 4 – Add Required Extensions

There are a large number of extensions available for Visual Studio Code like C#, Python, JavaScript, Google Chrome, etc. Install the required extensions to enhance your working experience with Visual Studio Code.

Conclusion

This tutorial helped you to install Visual Studio Code on Fedora and CentOS Linux systems.

Ref From: tecadmin

Related articles