X

Oracle Linux, virtualization , Enterprise and Cloud Management Cloud technology musings

Installing Visual Studio Code on Oracle Linux 7

Visual Studio Code is a popular editor. There is an RPM available for "el7" from the Microsoft yumrepo. This RPM can be manually downloaded on Oracle Linux 7 and installed with # yum localinstall code...  or # rpm -ivh code... but it's easier to just create a yum repo file so that you can just do # yum install code and # yum update code.

Here's an example. On Oracle Linux 7 (not 6), as user root:

# cd /etc/yum.repos.d

create a file, let's say vscode.repo with the following content:

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

 

and now you can just do

# yum install code
Loaded plugins: langpacks, ulninfo
vscode                                                   | 2.9 kB     00:00     
Resolving Dependencies
--> Running transaction check
---> Package code.x86_64 0:1.18.1-1510857496.el7 will be installed
y
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
 Package      Arch           Version                       Repository      Size
================================================================================
Installing:
 code         x86_64         1.18.1-1510857496.el7         vscode          63 M

Transaction Summary
================================================================================
Install  1 Package

Total download size: 63 M
Installed size: 186 M
Is this ok [y/d/N]: Downloading packages:
code-1.18.1-1510857496.el7.x86_64.rpm                      |  63 MB   00:41     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Warning: RPMDB altered outside of yum.
  Installing : code-1.18.1-1510857496.el7.x86_64                            1/1
  Verifying  : code-1.18.1-1510857496.el7.x86_64                            1/1

Installed:
  code.x86_64 0:1.18.1-1510857496.el7                                           

Complete!

That's it.

 

Be the first to comment

Comments ( 0 )
Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.