Pacman + Makepkg + AUR helper yay

Pacman

To update Arch Linux run:

pacman -Syu

To change settings or to check which repositories require signed packages, edit the pacman.conf file.

nano /etc/pacman.conf

I recommend to encrypt (https) the download of the upgrades as well by editing the mirrorlist’s in use in:

/etc/pacman.d/*****

Show all installed packages by user

pacman -Qet

Show all installed packages

pacman -Qn

Show aur packages

pacman -Qm

Show all not required packages

pacman -Qdt

Remove orpahned packages (installed packages of not anymore installed applications):

pacman -Rns $(pacman -Qtdq)

Pacman bugs

Since version 5 pacman doesn’t show the path of the locked database anymore, leaving the user in the dusk what he can do to continue. It is not unusual that the pacman database is locked by a not finished previous activity, so this case should be covered by pacman. Another this is that pacman shows you “there is no database error”, this is a bad style of telling the user that the database is OK where the only thing you usually see first is ERROR.

Enable AUR

https://wiki.archlinux.org/index.php/Arch_User_Repository

pacman -S --needed base-devel git

yay

Yay (license GPLv3, https://github.com/Jguer/yay) is a helper to upgrade all normal pacman and AUR packages. Normal upgrade command:

yay -Syu

If you want to always get a nicely colorful formatted list, be able to edit PKGBUILDS and to skip the diffmenu, run one time:

yay --combinedupgrade --editmenu --nodiffmenu --save

Additionall enable “color” in /etc/pacman.conf.

Bug: yay cannot use edited dependencies of PKGBUILD’s. See https://github.com/Jguer/yay/issues/793. Workaround: use pikaur

pikaur

Yaourt is deprecated. For most of the tasks yay is a much better replacement. But as yay cannot use edited dependencies, you can use pikaur for this task.

Makepkg

nano /etc/makepkg.conf

For a AMD Ryzen 7 with 8 cores and 16 threads, it would be the number of maximum treads:

MAKEFLAGS=”-j16″

Mirror List Update

You can use reflector to regularly update your mirror list. Command e.g.:

reflector --verbose --latest 10 --number 10 --age 3 --protocol https --sort rate --save /etc/pacman.d/mirrorlist

Another (but not yet stable approach, test phase) is to use IPFS to download from a P2P network all updates, read:

https://github.com/ipfs/notes/issues/84

https://github.com/victorb/arch-mirror

Reproducible Builds

There is an ongoing effort to create reproducible builds on Arch Linux, for details read http://vdwaa.nl/arch/linux/reproducible/builds/security/reproducible-builds-arch. The actual reproducible and failing packages can be found here https://tests.reproducible-builds.org/archlinux/archlinux.html.

Flatpak

Flatpak’s provide distribution independent software including sand-boxing technics. Available software can be found here:

https://flathub.org/home

Flatpak provides a per-bundled SDK or run-time for all apps. Example: https://gitlab.com/freedesktop-sdk/freedesktop-sdk/wikis/Release-Contents

Every Flatpak app comes bundled with all required dependencies, but Flatpak will only store a dependency once if another app is using the same one, read https://blogs.gnome.org/alexl/2017/10/02/on-application-sizes-and-bloat-in-flatpak/. Then add the official flathub repository and e.g. the KDE testing one (see https://community.kde.org/Guidelines_and_HOWTOs/Flatpak for more details):

flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
flatpak remote-add --if-not-exists kdeapps --from https://distribute.kde.org/kdeapps.flatpakrepo

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.