Sublime text on Arch linux OS

Viewed 802

I'm using

Linux archbios 5.13.6-arch1-1 #1 SMP PREEMPT Thu, 29 Jul 2021 00:21:06 +0000 x86_64 GNU/Linux

operating system.

My problem comes after following the sublime official instructions for Arch. After these steps from sublime official docs, I just need to upgrade the sublime

sudo pacman -Syu sublime-text

I don't understand from where comes this error

sudo pacman -Syu sublime-text
:: Synchronizing package databases...
 core                   136.1 KiB   340 KiB/s 00:00 [##########################] 100%
 extra                 1566.4 KiB  3.00 MiB/s 00:01 [##########################] 100%
 community                5.6 MiB  3.16 MiB/s 00:02 [##########################] 100%
 multilib               149.8 KiB  1248 KiB/s 00:00 [##########################] 100%
 sublime-text is up to date
:: Starting full system upgrade...
error: failed to prepare transaction (package architecture is not valid)
:: package sublime-text-4113-1-aarch64 does not have a valid architecture

I've checked /etc/pacman.conf

#SigLevel = Optional TrustAll
#Server = file:///home/custompkgs

[sublime-text]
Server = https://download.sublimetext.com/arch/stable/x86_64
3 Answers

Not quit sure, maybe problem is that when you type

pacman -Syu sublime-text // it takes default version for "sublime-text-4113-1-aarch64

but with yay and mention from where works,

yay -S aur/sublime-text-4

with this command it just works

I think I pasted the wrong version into the commandline and now have aarch64 errors also.

Removed the URL reference to aarch64 in the pacman.conf file which fixed half the problem.

Moved the var/lib/pacman/sync files into a backup directory. Re-ran the command:

sudo pacman -Syu sublime-text

FINALLY worked.

I can confirm Lord High Fixer's solution worked for me as well. I accidentally picked the wrong channel for aarch64 at first, then even after removing that channel from /etc/pacman.conf, I would continue getting the "package sublime-text-4113-1-aarch64 does not have a valid architecture" error.

I created a 'backup folder' in /var/lib/pacman/sync and moved sublime-text.db and sublime-text.db.sig into the folder. Ran pacman -Syu sublime-text and it installed correctly.

Related