Artix Linux: Add Arch Linux repos, extra + community
Tags: artix, archlinux, pacman, aur
Published: 2021-07-28 12:01:00

When you use [Artix Linux](https://artixlinux.org/) based on [Arch Linux](https://archlinux.org/), and some of \* Arch \* Linux repositories are missing with [`pacman`](https://wiki.archlinux.org/title/pacman) in your operation system, this post might be useful.

According to Artix Linux announcement, the repositories of [extra] / [community] are disabled by default:

> Artix has reached the stage where it can operate without the help of the Arch repositories, including the preparation of its installation media.

> As such, all new weekly ISO images will ship without [extra], [community] and [multilib] enabled in pacman.conf.

Here shows how to enable those repositories. Well, the detail is in [Artix official wiki](https://wiki.artixlinux.org/Main/Repositories#Arch_repositories).

First, activate [Universe repository](https://wiki.artixlinux.org/Main/Repositories#Universe):

```console
# nvim /etc/pacman.conf
```

by appending the lines:

```diff
+ [universe]
+ Server = https://universe.artixlinux.org/$arch
+ Server = https://mirror1.artixlinux.org/universe/$arch
+ Server = https://mirror.pascalpuffke.de/artix-universe/$arch
+ Server = https://artixlinux.qontinuum.space/artixlinux/universe/os/$arch
+ Server = https://mirror1.cl.netactuate.com/artix/universe/$arch
+ Server = https://ftp.crifo.org/artix-universe/$arch
+ Server = https://artix.sakamoto.pl/universe/$arch
```

Then sync:

```console
# pacman -Sy
```

Next, install `artix-archlinux-support`:

```console
# pacman -Syu artix-archlinux-support
```

The output was:

```console
:: Synchronizing package databases...
 (...)
 universe is up to date
:: Starting full system upgrade...
resolving dependencies...
looking for conflicting packages...

Packages (3) archlinux-keyring-20230320-1  archlinux-mirrorlist-20230226-2
             artix-archlinux-support-2-1

Total Download Size:   1.16 MiB
Total Installed Size:  1.65 MiB

:: Proceed with installation? [Y/n] y
:: Retrieving packages...
 archlinux-keyrin...  1165.1 KiB   787 KiB/s 00:01 [######################] 100%
 artix-archlinux-...    14.6 KiB  71.9 KiB/s 00:00 [######################] 100%
 archlinux-mirror...     9.2 KiB  45.5 KiB/s 00:00 [######################] 100%
 Total (3/3)          1188.9 KiB   476 KiB/s 00:03 [######################] 100%
(3/3) checking keys in keyring                     [######################] 100%
(3/3) checking package integrity                   [######################] 100%
(3/3) loading package files                        [######################] 100%
(3/3) checking for file conflicts                  [######################] 100%
(3/3) checking available disk space                [######################] 100%
:: Processing package changes...
(1/3) installing archlinux-keyring                 [######################] 100%
==> Appending keys from archlinux.gpg...
==> Locally signing trusted keys in keyring...
  -> Locally signed 5 keys.
==> Importing owner trust values...
gpg: (...)
==> Disabling revoked keys in keyring...
  -> Disabled 34 keys.
==> Updating trust database...
gpg: (...)
==> Updating trust database...
gpg: next trustdb check due at 2023-07-03
(2/3) installing archlinux-mirrorlist              [######################] 100%
(3/3) installing artix-archlinux-support           [######################] 100%
Optional dependencies for artix-archlinux-support
    lib32-artix-archlinux-support: archlinux multilib support
:: Running post-transaction hooks...
(1/1) Show archlinux help...
==> Add the arch repos in pacman.conf:

#[testing]
#Include = /etc/pacman.d/mirrorlist-arch


[extra]
Include = /etc/pacman.d/mirrorlist-arch


#[community-testing]
#Include = /etc/pacman.d/mirrorlist-arch


[community]
Include = /etc/pacman.d/mirrorlist-arch


#[multilib-testing]
#Include = /etc/pacman.d/mirrorlist-arch


#[multilib]
#Include = /etc/pacman.d/mirrorlist-arch

==> run: 'pacman-key --populate archlinux'
```

Next, edit `pacman.conf`:

```console
# nvim /etc/pacman.conf
```

to append these lines:

```diff
+ #[testing]
+ #Include = /etc/pacman.d/mirrorlist-arch
+ 
+ 
+ [extra]
+ Include = /etc/pacman.d/mirrorlist-arch
+ 
+ 
+ #[community-testing]
+ #Include = /etc/pacman.d/mirrorlist-arch
+ 
+ 
+ [community]
+ Include = /etc/pacman.d/mirrorlist-arch
+ 
+ 
+ #[multilib-testing]
+ #Include = /etc/pacman.d/mirrorlist-arch
+ 
+ 
+ #[multilib]
+ #Include = /etc/pacman.d/mirrorlist-arch
```

Then, run the command:

```console
# pacman-key --populate archlinux
```

The output was:

```console
==> Appending keys from archlinux.gpg...
==> Updating trust database...
gpg: next trustdb check due at 2023-07-03
```

That's it.
It is able now to install a package in [extra] or [community] repositories such as [Deno](https://deno.land/) :)