Alpine Linux, Arch Linux and Void Linux package manager Rosetta
By chimo on (updated on )I used Arch Linux for several years and I know its package manager (pacman) fairly well. These days, I mostly use Alpine Linux along with one server running Void Linux. Sometimes, I know how to do something with pacman (ex: find which package owns a certain file), but I’m not sure how to do that thing in one of the other distros.
Inspired by Archlinux’s Pacman Rosetta wiki page, I’ve jotted down some equivalent commands between the three package managers for things I do somewhat frequently. This isn’t meant to be an exhaustive list and only shows one way of doing things (only the short flags, for example).
I might add more things over time if I find myself running in other use-cases often.
Action | Alpine Linux | Arch Linux | Void Linux |
---|---|---|---|
Query the package which provides FILE | apk info -W FILE | pacman -Qo FILE | xbps-query -o FILE |
List dependencies of PKG | apk info -R PKG | pacman -Qi PKG | xbps-query -x PKG |
List reverse dependencies of PKG | apk info -r PKG | pacman -Qii PKG | xbps-query -X PKG |
List packages installed explicitly | cat /etc/apk/world | pacman -Qe | xbps-query -m |