1

VSCode new update 1.71 is available. I currently have VSCode 1.70 I download the .deb package for ubuntu and VSCode will not update. Similar questions have been asked and most popular response is to do the following: sudo apt-get update after that i run the following sudo apt-get update code computer than tells me Reading package lists... Done Building dependency tree... Done Reading state information... Done code is already the newest version (1.70.2-1660629410) Help Please!

2 Answers2

1

It looks like you're mixing up two different levels here. apt works with repositories that are defined in your sources.list (and accompanying files). Those repositories contain deb packages. But that doesn't mean that apt knowns about any deb packages that you downloaded and stored somewhere on your file system ;)

There are basically two things you can do. The first way, which I would recomend, is to wait until the the repository you installed the code package originally from has updated to the 1.71 version. Then, the new version should appear in your updates automatically.

The second way is to install the deb file you've downloaded manually with dpkg. But this way, you are responsible for any depedencies, incompatibilities and so forth yourself.

0
sudo apt-get update code

update does not accept anything behind it.

If you download a .deb you need to use dpkg to install it, not apt. apt will only update from the repositories. That would be:

sudo dpkg --install {package.db}

You will also need to take care of dependencies if there are any.

Other method using apt:

To get 1.72 you can use this to add a key, add the 3rd party ppa from microsoft, and update/upgrade to the newest version:

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

and for 1.72 you install it with

sudo apt install code-insider

or 1.71 with

sudo apt install code

That method will also add newer version when those get released.

Rinzwind
  • 299,756