I shifted to Ubuntu 20.04 LTS 3 weeks ago from Windows 10. I use Visual Studio Code and whenever I get an update in Update it shows in Settings > Download Update(1). When I click on download update, firefox opens up and then I have to download Visual Studio Code Setup from there and then I have to install it. This is what I have to do everytime. In Windows, I just had to click the Download Update button then the update would automatically be downloaded.
Please tell me if there is any way to update Visual Studio Code easily like using termianl?
Thanks in Advance
PS: Sorry for my bad English as it's not my native language, I may have committed some grammatical mistakes.
33 Answers
After installing, you should have the following file:/etc/apt/sources.list.d/vscode.listwith this content:
deb [arch=amd64] stable mainThis will allow you to update it with apt
sudo apt update
sudo apt upgrade 1 Assuming you've installed snapd package using $ sudo apt install snapd. First remove all other(.deb) version(s) of VSCode, then run:
$ sudo snap install code --classicThis installs VSCode which automatically gets updated but if you like to manually check and trigger an update, run:
$ snap refresh In my case it was not a straight forward upgrade. I tried to upgrade VS Code with the following commands
sudo apt install apt-transport-https
sudo apt updateand I got the following error
Then I used the following process to upgrade VS Code.
- Downloaded the .deb file from website
- Executed following command
sudo dpkg -i <file>.deb&sudo apt-get install -f # Install dependencies - Executed the commands in the sequence sequence
wget -qO- | gpg --dearmor > packages.microsoft.gpgsudo install -o root -g root -m 644 packages.microsoft.gpg /etc/apt/trusted.gpg.d/sudo sh -c 'echo "deb [arch=amd64,arm64,armhf signed-by=/etc/apt/trusted.gpg.d/packages.microsoft.gpg] stable main" > /etc/apt/sources.list.d/vscode.list'- Then update the package cache and install the packages
$ sudo apt install apt-transport-https$ sudo apt update$ sudo apt install code # or code-insiders
and DONE.
Ref: