AUR-REPO(1)

NAME
aur-srcinfo - generate, parse or pretty-print .SRCINFO files

SYNOPSIS
aur srcinfo [-C directory] [-NUPJ] [-Q jq-arg-or-expr ...]
aur srcinfo [-M] [-NUPJ] [-Q jq-arg-or-expr ...] [directories...]

DESCRIPTION
aur-srcinfo helps maintain or process .SRCINFO files used by makepkg(8) as a companion file format alongside PKGBUILDs. In particular, it serves to generate or update .SRCINFO files from PKGBUILD content (which happens automatically, unless -N, --no-update is passed), print them to stdout (which is the default action), parse them into a JSON-like human-readable format (-P, --parse) or actual JSON (-J, --json), or pipe them into jq(1) for further processing. By default, aur-srcinfo operates on the current directory, which can be overridden with the -C option. Alternatively, the -M option may be provided, in which case aur-srcinfo will operate on multiple directories provided as positional arguments.

TARGET SELECTION OPTIONS

-C DIRECTORY, --directory=DIRECTORY
    Operate on the given DIRECTORY instead of the current working directory.

-M, --multiple
    Operate on multiple directories provided as positional arguments.

OPERATIONS

-N, --no-update
    Do not update .SRCINFO even if it is older than PKGBUILD.

-U, --update-only
    Do not output the .SRCINFO, only update it as necessary.

-P, --parse
    Pretty-print the .SRCINFO contents in a human-readable JSON-like format.

-J, --json
    Print the .SRCINFO contents in a JSON representation.

-Q JQ-EXPRESSION, --jq=JQ-EXPRESSION
    Pipe the JSON representation of the .SRCINFO into jq(1) for further processing using the provided JQ-EXPRESSION. This option may be repeated to pass more than one argument to jq(1) (for instance, -r).

EXAMPLES
Output contents of all .SRCINFO files for locally downloaded package sources, updating them as necessary:

      $ dirname -z **/PKGBUILD | xargs -0 aur srcinfo -M

Print all pkgnames declared in the locally downloaded package sources:

      $ dirname -z **/PKGBUILD | xargs -0 aur srcinfo -M -Q '.packages | keys[]' -Q -r

Or, equivalently:

      $ dirname -z **/PKGBUILD | xargs -0 aur srcinfo -M -J | jq -r '.packages | keys[]'

SEE ALSO
aur(1), makepkg(8)

AUTHORS
Alad Wenter (https://github.com/AladW), Ivan Shapovalov (https://github.com/intelfx)