aur-fetch
aur-fetch
is used to download package build files from the AUR.
Synopsis
aur fetch [options] <pkgbase...>
Description
aur-fetch
downloads AUR packages using git
. It clones repositories that don't exist locally and fetches updates for those that do.
By default, it only runs git fetch
. You can control how upstream changes are integrated using the --sync
option or its aliases (--merge
, --rebase
, --reset
).
Options
--sync=<mode>
: Specifies how to integrate upstream changes. The mode can be one of:fetch
(default): Only rungit fetch
.merge
: Fetch and then merge changes usinggit merge --ff-only
.rebase
: Fetch and then re-apply local commits on top of upstream changes usinggit rebase
.reset
: Fetch and then hard reset the local branch to the upstream branch, discarding all local changes and commits (git reset --hard origin/master
).auto
: Userebase
ifaurutils.rebase
is set totrue
in the repository's git config, otherwise usemerge
.
--merge
: Alias for--sync=merge
.--rebase
: Alias for--sync=rebase
.--reset
: Alias for--sync=reset
.--discard
: Discard uncommitted local changes before merging or rebasing.-r
,--recurse
: Download the package and all of its AUR dependencies recursively. Target arguments are treated as package names, not package bases.--existing
: Before fetching, check if the package exists in the AUR usinggit ls-remote
.--results=FILE
: Write a colon-delimited log of actions toFILE
. The format is<action>:<head_from>:<head_to>:file://<path>
.
Environment Variables
AUR_LOCATION
: The base URL for cloning AUR git repositories. Defaults tohttps://aur.archlinux.org
.AUR_FETCH_USE_MIRROR
: If set to a positive integer, clones from an AUR mirror (github.com/archlinux/aur
by default) where each package is a separate branch.