Arch Linux pacman
(See the docs
for more details, of which the below text is a selective summary.)
Table of Contents
Query/info
pacman -Qs $my_regex
: search for RE in local databasepacman -Ss $my_regex
: search for RE in list of available packagespacman -Si $my_pgk_name
: display info about packagepacman -Ql $my_pkg_name
: display list of files installed by a package
(usepkgfile -l <pkgname>
to display contents for not-installed packages)pacman -Qo $my_file_path
: find out to which a package a local file belongspacman -Qdt
: list orphaned packagespacman -Qet
: list explicitly installed packages (in contrast to pulled-in deps)pactree -a $my_pkg_name
: list dep-tree of a package (-a
is for ASCII-tree-chars)whoneeds $my_pkg_name
orpactree -ar $my_pkg_name
: find out who depends on a package
the system – partial upgrade is not supported.
Adding/removing
pacman -S $my_pkg_name
: install package(s)pacman -R $my_pkg_name
: remove package only – leave deps installedpacman -Rs $my_pkg_name
: remove package and all its would-be orphaned deps
Maintenance
pacman -Sc
: clean up cache from downloaded and old packagespacman -Sy
: DO NOT use this; it refreshes the package list without upgradingpacman -Syu
: sync repo-db and update all packagescheckupdates
: check for updates (but do not update, as perpacman -Syu
)makepkg -si
: create/install package from descr (incl. PKGBUILD) in a local dir
Read more here: Source link