PKG-RQUERY(8)

πŸ“¦ version 2.7.5, in nixos 26.05, nixpkgs unstable

πŸ’… PKG-RQUERY β€” a love letter to remote repo queries

okay so bestie, this is the manual page for pkg rquery (section 8 of the System Manager's Manual, if you're keeping track) and it is literally the tool that lets you peek at what's inside your remote repositories without installing anything. Think of it as stalking your crush's profile instead of actually DMing them. No cap. πŸ¦‹


✨ NAME ✨

pkg rquery β€” query information from remote repositories


🌸 SYNOPSIS 🌸

pkg rquery -I|query-format pkg-name
pkg rquery [-aU] [-r reponame ...] -I|query-format
pkg rquery [-U] [-Cgix] [-e evaluation-condition] [-r reponame ...]
    -I|query-format pattern ...

πŸŽ€ DESCRIPTION πŸŽ€

pkg rquery is your girl for displaying information about remote packages. Not local ones β€” remote. Respect the distinction, it's giving boundaries. ✨

Also, heads up: package repository catalogues get automatically updated whenever pkg rquery runs, but only if you're a user ID with write access to the package database. Not the case? You can turn the whole thing off with the -U flag, or by setting REPO_AUTOUPDATE to β€œNO” in pkg.conf(5). Your call, main character. πŸ’…


πŸ”₯ OPTIONS πŸ”₯

The following options are supported by pkg rquery. All of them. Yes queen, read them all.

  • -a, --all β€” match all packages from the database. Every single one. no skips.
  • -C, --case-sensitive β€” makes the standard match, or the regular expression match (-x), against pkg-name in pattern case sensitive. Uppercase girlies matter too.
  • -e evaluation-condition, --evaluate evaluation-condition β€” match packages using the given evaluation-condition. Peep the β€œEVALUATION FORMAT” section below for the deets, iykyk.
  • -I, --index-line β€” prints out the corresponding line from the ports INDEX file for each matched package. This is a shorthand query-format argument. ⚠️ Only the first query format (including the -I option) on the command line will be interpreted. First come, first served, periodt.
  • -r reponame, --repository reponame β€” query for data about packages from only the named repository. Can be specified multiple times to use several repositories. Data gets queried from the named repositories only, irrespective of the configured β€œenabled” status from repo.conf. By default, catalogues for all enabled repositories are queried. 🫢
  • -g, --glob β€” treat pattern as a glob pattern.
  • -i, --case-insensitive β€” makes the standard match, or regular expression (-x) match, against pkg-name in pattern case insensitive. πŸ’– This is the default, unless you go modify it by setting CASE_SENSITIVE_MATCH to β€œtrue” in pkg.conf.
  • -U, --no-repo-update β€” suppresses the automatic update of the local copy of the repository catalogue from remote. Real talk: automatic repository catalogue updates are only attempted when the effective UID of the process has write access to the package database. Otherwise they're silently ignored. Like, ghosted. πŸ‘»
  • -x, --regex β€” treat pattern as a regular expression according to the β€œmodern” or β€œextended” syntax of re_format(7).

🌈 QUERY FORMAT 🌈

There are two types of keywords for the query format: the multiline one and the normal one. Only one type of multiline pattern is accepted for a given query. Pick a lane, bestie. πŸ’…

πŸ’œ Normal patterns:

  • %R β€” name of the repository the package is in
  • %n β€” name of the matched package
  • %v β€” version of the matched package
  • %o β€” origin of the matched package
  • %p β€” prefix of the matched package
  • %m β€” maintainer of the matched package
  • %c β€” comment of the matched package
  • %e β€” description of the matched package
  • %w β€” home page of the matched package
  • %q β€” architecture of the matched package
  • %l β€” license logic of the matched package. One of the following will be printed:
    • β€œsingle” if the package is distributed under one license
    • β€œand” if the package is multi-licensed
    • β€œor” if the package is dual-licensed
  • %s[bh] β€” the flat size of the matched package, where b is in bytes, and h is in human readable format
  • %M β€” message contained in the matched package
  • %?[drCOLBbA] β€” returns 0 if the list is empty and 1 if the list has information to display:
    • d for dependencies
    • r for reverse dependencies
    • C for categories
    • O for options
    • L for licenses
    • B for required shared libraries
    • b for provided shared libraries
    • A for annotations
  • %#[drCOLBbA] β€” returns the number of elements in the list:
    • d for dependencies
    • r for reverse dependencies
    • C for categories
    • O for options
    • L for licenses
    • B for required shared libraries
    • b for provided shared libraries
    • A for annotations

πŸ¦‹ Multiline patterns:

  • %d[nov] β€” expands to the list of dependencies for the matched package, where n stands for the package name, o for the package origin, and v for the package version.
  • %r[nov] β€” expands to the list of reverse dependencies for the matched package, where n stands for the package name, o for the package origin, and v for the package version.
  • %C β€” expands to the list of categories the matched package belongs to.
  • %O[kvdD] β€” expands to the list of options of the matched package, where k stands for option key, v for option value, d for option default value, and D for option description. ⚠️ Option default values and descriptions are optional metadata and may be blank for certain packages or repositories. Not everyone fills out their whole profile, y'know?
  • %L β€” expands to the list of license(s) for the matched package.
  • %B β€” expands to the list of shared libraries used by programs from the matched package.
  • %b β€” expands to the list of shared libraries provided by the matched package.
  • %A[tv] β€” expands to the list of annotations associated with the matched package, where t stands for the annotation tag, and v stands for the annotation value.

⭐ EVALUATION FORMAT ⭐

πŸ’– Variables

  • %n β€” name of the package (type string)
  • %o β€” origin of the package (type string)
  • %p β€” prefix of the package (type string)
  • %m β€” maintainer of the package (type string)
  • %c β€” comment of the package (type string)
  • %e β€” description of the package (type string)
  • %w β€” WWW address of the package (type string)
  • %s β€” flatsize of the package (type integer)
  • %a β€” automatic status of the package (type integer)
  • %q β€” architecture of the package (type string)
  • %M β€” message of the package (type string)
  • %#[drCOLBbA] β€” number of elements in the list of information (type integer). See %? above for what information is used. πŸ”

🧚 Operators

  • var ~ glob β€” the string value of var matches the given glob pattern.
  • var !~ glob β€” the string value of var does not match the given glob pattern.
  • var >[=] num β€” the numerical value of var is greater than [or equal to] the given number.
  • var <[=] num β€” the numerical value of var is less than [or equal to] the given number.
  • var =[=] [num | string] β€” the value of var is equal to the given number or string.
  • var =~ [num | string] β€” the value of var is equal (case insensitive) to the given number or string.
  • var != [num | string] β€” the value of var is not equal to the given number or string.
  • var !=~ [num | string] β€” the value of var is not equal, case insensitive, to the given number or string.

πŸ“ ENVIRONMENT πŸ“

The following environment variables affect the execution of pkg rquery. See pkg.conf(5) for further description. πŸ’…

  • PKG_DBDIR
  • CASE_SENSITIVE_MATCH

🌸 FILES 🌸

See pkg.conf(5).


🫢 EXIT STATUS 🫢

The pkg rquery utility exits 0 on success, and >0 if an error occurs. Simple as that, bestie. ✨


πŸ‘‘ EXAMPLES πŸ‘‘

See pkg-query(8) for example usage. (Yes, that's it. She's lowkey pointing you at her sister's page. Iconic behavior, honestly.)


πŸ“š SEE ALSO πŸ“š

pkg_create(3), pkg_printf(3), pkg_repo_create(3), pkg_repos(3), pkg-keywords(5), pkg-lua-script(5), pkg-repository(5), pkg-script(5), pkg-triggers(5), pkg.conf(5), pkg(8), pkg-add(8), pkg-alias(8), pkg-annotate(8), pkg-audit(8), pkg-autoremove(8), pkg-check(8), pkg-clean(8), pkg-config(8), pkg-create(8), pkg-delete(8), pkg-fetch(8), pkg-help(8), pkg-info(8), pkg-install(8), pkg-key(8), pkg-lock(8), pkg-plugins(8), pkg-query(8), pkg-register(8), pkg-repo(8), pkg-repositories(8), pkg-search(8), pkg-set(8), pkg-shell(8), pkg-shlib(8), pkg-ssh(8), pkg-stats(8), pkg-triggers(8), pkg-unregister(8), pkg-update(8), pkg-updating(8), pkg-upgrade(8), pkg-version(8), pkg-which(8)

That's the whole squad omg πŸ’€πŸ’–


okay that's the page!! this one's brought to you by the Debian girlies, dated July 7, 2024, and honestly? she ate. go query something, bestie πŸŽ€βœ¨

πŸ“¦ where this page comes from