This document is a WORK IN PROGRESS.
This is just a quick personal cheat sheet: treat its contents with caution!
Yay¶
Yay is an AUR helper (written in Go). AUR helpers automate usage of the AUR (like search for AUR packages, resolving dependencies, retrieve and build AUR packages, etc).
Reference(s)
Table of contents¶
Install¶
Update your system and install the needed packages:
$ sudo pacman -Syu
$ sudo pacman -S --needed git base-devel
$ git clone https://aur.archlinux.org/yay-bin.git
$ cd yay-bin
$ makepkg -si
$ cd ..
$ rm -rf yay-bin
$ yay --version
Config¶
First use:
-
Run
yay -Y --gendb
to generate a development package database for*-git
packages that were installed without yay. This command should only be run once. -
Run
yay -Syu --devel
in order to check for development package updates. -
Run
yay -Y --devel --save
in order to make development package updates permanently enabled (yay
andyay -Syu
will then always check for dev packages).
Use¶
-
Update all the system and packages (not only AUR ones):
-
First, check the latest news: https://www.archlinux.org/news/
-
Then, update:
-
-
Update AUR packages only:
-
Check updates for all the system and packages (not only AUR ones):
-
Check updates for AUR packages:
-
Search for a package (not only AUR one):
-
Install a package (not only AUR}:
-
Print package information:
-
List packages not installed from the main repos (i.e. AUR, pkgbuild, ...):
-
Remove a package:
-
Remove a package and its dependencies, provided those dependencies are not required by any other instlled package :
-
Remove a package and its dependencies, provided those dependencies are not required by any other instlled package, and remove the configuration files generated by Pacman:
-
Clean package cache:
-
Clean unneeded dependencies:
-
Print system statistics:
-
Unvote for package (requires setting
AUR_USERNAME
andAUR_PASSWORD
environment variables): -
Vote for package (requires setting
AUR_USERNAME
andAUR_PASSWORD
environment variables): -
Keep a list of all explicitly installed packages (for later backup or quick installation of a new system):
To install packages from the previously saved list of packages, while not reinstalling already installed packages that are up-to-date, run:
See https://wiki.archlinux.org/title/Pacman/Tips_and_tricks#List_of_installed_packages.
Troubleshooting¶
Packages to exclude
¶
Try to never exclude exclude packages when asked. Excluding packagges may cause partial upgrades
and break systems). Instead just hit
Packages to cleanBuild?
¶
When asked Packages to cleanBuild?
, it is recommanded to clean build only packages that cause
problem at installation (or update). If no package cause you any trouble,
you can just answer [N]one.
could not find all required packages: ...
¶
If the could not find all required packages: ...
error appears, then you can generally just clean
all unneeded dependencies : yay -Yc
.
If this cheat sheet has been useful to you, then please consider leaving a star here.