Score:0

Can't install Visual Code on Ubuntu

br flag

I recently installed Ubuntu and I am new to it. Now I wanted to program with Visual Code but the problem is I can't download it. I tried sudo apt install ./<file>.deb (with my file path of course) but I only get this Error:

The following packages have unmet dependencies:
 code:amd64 : Depends: libnss3:amd64 (>= 2:3.26) but it is not installable
              Depends: apt:amd64 but it is not installable
              Depends: libxkbfile1:amd64 but it is not installable
              Depends: libsecret-1-0:amd64 but it is not installable
              Depends: libgtk-3-0:amd64 (>= 3.10.0) but it is not installable
              Depends: libxss1:amd64 but it is not installable
              Depends: libgbm1:amd64 but it is not installable
E: Unable to correct problems, you have held broken packages.

I also had a lot of problems with installing anything including changing the keyboards layout.

I'm on a M1 MacBook and using Parallels Desktop.

Output of sudo apt update:

Hit:1 http://ports.ubuntu.com/ubuntu-ports focal InRelease
Hit:2 http://ports.ubuntu.com/ubuntu-ports focal-updates InRelease
Hit:3 http://ports.ubuntu.com/ubuntu-ports focal-backports InRelease
Hit:4 http://ports.ubuntu.com/ubuntu-ports focal-security InRelease            
Hit:5 https://packages.microsoft.com/repos/vscode stable InRelease             
Reading package lists... Done                           
Building dependency tree       
Reading state information... Done
All packages are up to date.

Output of sudo apt -f install:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

No output for dpkg --get-selections | grep hold

I appreciate any help.

Someone avatar
my flag
Related: [Unable to correct problems, you have held broken packages](https://askubuntu.com/questions/223237/unable-to-correct-problems-you-have-held-broken-packages)
Someone avatar
my flag
Welcome to Ask Ubuntu! Can you [edit] to include your Ubuntu version? Also, include the output of `sudo apt update` and `sudo apt -f install`. You may also include the output of `dpkg --get-selections | grep hold` if any.
Score:0
zw flag

M1 is ARM, so you can't install amd64 packages here.

But you can try installing VSCodium for ARM from https://github.com/VSCodium/vscodium/releases using one of the following commands (depending on CPU arch):

cd ~/Downloads
# 32-bit
wget -c https://github.com/VSCodium/vscodium/releases/download/1.63.2/codium_1.63.2-1639700511_armhf.deb
sudo apt-get install ./codium_1.63.2-1639700511_armhf.deb

# 64-bit
wget -c https://github.com/VSCodium/vscodium/releases/download/1.63.2/codium_1.63.2-1639700587_arm64.deb
sudo apt-get install ./codium_1.63.2-1639700587_arm64.deb
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.