Install and test Visual Studio Code on Ubuntu or Fedora

Visual Studio Code is a source code editor developed by Microsoft for Windows, Linux and macOS X. Launched in 2015, it became one of the preferred code editors in the StackOverflow developer community and has a huge marketplace with a lot of plug-ins and extensions.

 

Debug code right from the editor of Visual Studio Code on Linux
Debug code right from the editor of Visual Studio Code on Linux

Visual Studio Code powered by Electron, fast and reliable

Visual Studio Code includes support for debugging, embedded Git control, syntax highlighting, intelligent code completion, snippets, and code refactoring. It is also customizable, so users can change the editor’s theme, keyboard shortcuts, and preferences. It is free and open-source, although the official download is under a proprietary license.

Visual Studio Code has syntax highlighting and autocomplete with IntelliSense, which provides smart completions based on variable types, function definitions, and imported modules. Review diffs, stage files, and make commits right from the editor is fast and simple. Push and pull from any hosted Git service has never been easier.

 

Snap issue with Visual Studio Code on Fedora Linux
Snap issue with Visual Studio Code on Fedora Linux

Easy to install with .deb, .rpm and snap packages

You can easily install Visual Studio Code thank to the availability of many different packages. At the official download page, you can find .deb and .rpm packages, so install it on Debian and Fedora based platforms is really a simple thing.

There is also a third way to install Visual Studio Code on Linux systems like Fedora and Ubuntu: the snap package.

To install Visual Studio Code as a snap in Ubuntu:

$ sudo snap install --classic vscode

To install Visual Studio Code as a snap in Fedora:

$ sudo dnf install snapd
$ sudo snap install --classic vscode

But there is an issue because Snap on Fedora is still under development and so you got an error:

$ sudo snap install --classic vscode
error: cannot install "vscode": classic confinement is not yet supported on
your distribution

If you try to install it without the –classic option, you got:

$ sudo snap install vscode
error: This revision of snap "vscode" was published using classic confinement
and thus may perform arbitrary system changes outside of the security
sandbox that snaps are usually confined to, which may put your system at
risk.

If you understand and want to proceed repeat the command including
--classic.

So, actually, the only way to install Visual Studio Code on Fedora is through a classic .rpm package, because the Flatpack option is still far away.

3 comments

Leave a Reply

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