There are two types of repositories on Arch Linux: official repositories (accesible via pacman) and the Arch User Repository. In this tutorial you will understand the differences and how to install packages from each one.

Table of Contents

Official repositories

Contain essential and popular software you can install via pacman (Check Package managers in Linux). These packages are constantly upgraded: do not depend on the operating system version, like in Ubuntu, whose official repositories only receive security and minor package upgrades until a new version of Ubuntu is released.

Inside these official respositories there are two types: stable and testing. Inside stable repositories there are four repositories:

  • core (needed packages for Arch Linux to work).
  • extra (packages that do not fit in “core”, like Xorg, web browsers, media players, etc.).
  • community (popular software in AUR that have been adopted by Trusted Users).
  • multilib (32-bit software and libraries that can be used to run and build 32-bit applications on 64-bit installs).

Arch User Repository

It’s a community-driven repository. This repository doesn’t contain binaries (software compiled) but package descriptions (PKGBUILD) that allow you to compile the software and then install it with pacman.

Installing software

The process of installing software from AUR is relatively simple:

  1. (Prerequisite) Install base-devel and git packages.
    sudo pacman -S --needed base-devel git
    
  2. Search the package you want in AUR home page.
  3. Clone its git repository.
    git clone https://aur.archlinux.org/package_name.git
    

    AUR page

    • You can also download a snapshot and unpack it.
  4. Acquire a PGP public key if needed (More info).
  5. Build the package.
    cd <package_name>
    
    # review PKGBUILD for malicious or dangerous commands
    less PKGBUILD
    
    # make the package
    makepkg
    
  6. Install the package with pacman.
    sudo pacman -U <package_name>-<version>-<architecture>.pkg.tar.zst
    

AUR helpers

AUR helpers are programs that automate the process of search and install packages from AUR. Some helpers simplify the search and download process, others the search and build process and there are some helpers that work in a similar way to pacman. These are some examples:

yay

Works like pacman (Package managers), adding -a parameter to specify you want to use AUR.

  • Install
    sudo pacman -S --needed git base-devel
    git clone https://aur.archlinux.org/yay-bin.git
    cd yay-bin
    makepkg -si
    
  • Use (like pacman)
    # Search in AUR
    yay -aSs <search term>
    # Install an AUR package
    yay -aS <package name>
    

aura

git clone https://aur.archlinux.org/aura-bin.git
cd aura-bin
makepkg
sudo pacman -U <the-package-file-that-makepkg-produces>