8

I'm trying to install Visual Studio Code, I downloaded deb file and run it. Ubuntu Software was opened but unfortunately when I tried to click install button nothing happened (this is only happening with third-party software). I didn't even get any error message. What can be the problem?

4 Answers4

5

I don't know what the cause was, but I had the same issue. I could install other software, like chess. I couldn't install Atom, though.

I managed to install it from terminal, using command (in case you don't have gdebi, first type sudo apt install gdebi-core -y )

sudo gdebi code_XX.XXX.XXXXXXX_amd64.deb

where Xs are the version number. You have to run it from directory where you have the deb file.

banan314
  • 360
2

Another good way is to do it completely in the terminal and just type sudo dpkg -i vscode.deb where vscode.deb is the deb file that you downloaded.

0

The simplest way of installing vs code, is to setup a repository

curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg
sudo mv microsoft.gpg /etc/apt/trusted.gpg.d/microsoft.gpg
sudo sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list'

Then update the package cache and install the package using

sudo apt-get update
sudo apt-get install code # or code-insiders
Junius L
  • 253
  • 1
    Although code can be installed with this, it gives an error on Linux: To use Visual Studio Code with the Windows Subsystem for Linux, please install Visual Studio Code in Windows and uninstall the Linux version in WSL. You can then use the 'code' command in a WSL terminal just as you would in a normal command prompt. – Arnis Juraga Jan 27 '22 at 09:28
0

I found I needed to select "save file" instead of "open with" when downloading the package.