PACSIFT(1)
π PACSIFT(1) β the pacsift page, but make it make sense
okay so bestie, welcome to pacsift from the pacutils fam β this is PACSIFT(1), and it's the tool that queries and filters packages. literally the group chat of package data: you ask, it filters, it delivers. π
β¨ SYNOPSIS β¨
pacsift [options] (<field> <term>)...
pacsift (--help|--version)
that's the whole shape of it. options, then field/term pairs, or just ask for --help / --version and dip. π¦
πΈ DESCRIPTION πΈ
so here's the vibe: by default you get the intersection of matched packages β like, only the ones that hit on everything. but if you give the same field multiple times, you get the union of matches for that field instead. so --description pacman --description alpm is "either", and piping two calls together is "both". iykyk. π
oh, and important: if stdin is not connected to a terminal, the packages to filter get read from stdin. main character behavior fr fr.
you can combine it with pacinfo to show brief package info, kinda like pacman -Qs and pacman -Ss:
pacsift --name pacman | pacinfo --short
iconic. ate. no cap. π₯
π OPTIONS π
--config=pathβ set an alternate configuration file path.--dbext=extensionβ set an alternate sync database extension.--dbpath=pathβ set an alternate database path.--root=pathβ set an alternate installation root.--sysroot=pathβ set an alternate system root. go readpacutils-sysroot(7)for the lore.--null[=sep]β set an alternate separator for values parsed from stdin. the default is a newline"\n". if you use--nullwithout specifying sep,"NUL"gets used instead. π«Ά--existsβ exit with a non-zero value if no matches are found.--not-existsβ exit with a non-zero value if matches are found. (yes, it's the opposite, that's the whole point π)--invertβ return packages that DO NOT match the provided search terms. chaotic but valid.--anyβ return the union of matched packages rather than the intersection.--exactβ match values exactly. no fuzzy vibes.--regexβ treat string values as extended case-insensitive regular expressions.--helpβ display usage information and exit.--versionβ display version information and exit.
π§ Filters
filters limit the initial set of packages to be searched. heads up bestie: they may not be used if packages are provided on stdin, and they are not affected by --invert or --any. periodt. β
--localβ search locally installed packages. similar to:
pacsift --repo=local | pacsift ...
--syncβ search packages in sync databases. similar to:
pacsift --invert --repo=local | pacsift ...
--cache(EXPERIMENTAL) β search packages in cache directories. it's giving experimental, so, y'know. π
π String Fields
by default, string fields use a case-insensitive substring search. if --exact is used, string fields must match val exactly. if "--regex" is used, val becomes an extended case-insensitive regular expression. slay.
--repo=val--name=val--base=val--description=val--packager=val--group=val--owns-file=pathβ file paths must match the package database; no attempt is made to resolve the provided path. note: when used with--exact, the installation root will be removed from path if present, otherwise path is used exactly as provided. you can pair it withrealpathorwhichto more easily search for the owner of installed files:
pacsift --local --exact --owns-file="$(which pacsift)"
--license=val--url=val
π Dependency Fields
dependencies can be specified in the format "<pkgname>[<cmp><version]". "cmp" may be any of: "=", "<", "<=", ">", ">=". if "version" is provided, the package dependency must be an exact match to the search term. if "version" is omitted, only "pkgname" gets compared β unless --exact is used. and if "--exact" is used and "version" isn't provided, only dependencies with no version specified will be matched. got it? got it. π«‘
ngl, dependency fields are not affected by --regex.
--provides--conflicts--replaces--depends--optdepends
π Size Fields
size fields may be prefixed with any of these comparisons: "=", "!=", "<", "<=", ">", ">=". if no comparison is provided, "=" is used. the size may be followed by an abbreviated unit β and units are case-sensitive, so don't get cute with it. β¨
--size--installed-size--download-size
π¦ Date Fields
date fields may be prefixed with any of these comparisons: "=", "!=", "<", "<=", ">", ">=". if no comparison is provided, "=" is used. dates may be provided as seconds since the epoch, or as any of these "strptime" formats: "%Y-%m-%d", "%Y-%m-%d %H:%M", "%Y-%m-%d %H:%M:%S". π°οΈ
--install-date--build-date
π Other
--satisfies=dependencyβ search for packages that satisfy dependency.
π₯ EXAMPLES π₯
find broken packages:
pacsift --packager allan
find large installed packages:
pacsift --local --size '>1.5GB'
find packages with either "pacman" or "alpm" in their description:
pacsift --description pacman --description alpm
find packages with both "pacman" and "alpm" in their description:
pacsift --description pacman | pacsift --description alpm
check if a package is installed:
pacsift --local --exists --satisfies pacman && echo "pacman is installed"
see how it all comes together? that's the way that it works. π
π CAVEATS π
okay so real talk: pacsift decides whether to read packages from stdin based on a naive check using isatty(3). so if pacsift is called in an environment β like a shell function or script being used in a pipe β where stdin is not connected to a terminal but does not contain packages to filter, you should call pacsift with stdin closed. for POSIX-compatible shells, that's done with "<&-".
like, don't be weird about it, just close stdin. π
and that's the page, bestie π«Ά β this whole thing is from pacutils, version dated 2025-12-04, and honestly? she ate. go filter some packages. π β¨
π¦ where this page comes from
- arch rolling: pacutils 0.15.0-2 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms