Difference between revisions of "Pacaur"

From ArchWiki
Jump to: navigation, search
m (typo)
(info moved upstream, redirect)
(66 intermediate revisions by 16 users not shown)
Line 1: Line 1:
[[Category:Package management]]
#REDIRECT: [[AUR helpers]]
[[Category:Arch User Repository]]
{{Article summary start}}
{{Article summary text|How to install and use pacaur.}}
{{Article summary heading|Related}}
{{Article summary wiki|AUR Helpers}}
{{Article summary end}}
'''Pacaur''' is an [[Arch User Repository]] (AUR) [[AUR helpers|helper]] aiming at speed and simplicity, designed to minimize user prompt interaction and to use an uncluttered interface. It is written in Bash and built upon the well designed cower and expac C backends.
{{note|Pacaur is targeted to '''advanced users''' who want some degree of automation for repetitive tasks. As such, the user is expected to be familiar with the [[Arch User Repository|manual build process]]. }}
Pacaur main feature revolves around a ''fast workflow'' idea, that is, '''spending as less time as possible interacting with package management prompts'''. The objectives of ''speed'', ''simplicity'' and ''uncluttered interface'' were also taken into consideration.
Pacaur is:
* It minimizes user interaction.
* It has very good performance with minimal memory footprint.
* It retrieve and edit all PKGBUILDs, check and solve all conflicts before building anything.
* It does not add lot of features, but simply extends pacman to manage the AUR.
* It does not reinvent the wheel, but is built upon existing tools (cower, expac, sudo, pacman-color).
* It is a small bash script using tiny C libraries.
* It is based on libalpm C interface directly maintained by a pacman developer.
* It can be used as a separate AUR frontend, or a single tool to manage official and AUR packages.
* Its search function provides regex support (through cower).
* It provides binary and AUR package names completion.
* It passes arguments to pacman when appropriate.
* It shows current and available version when checking update.
* It does not source the PKGBUILDs unecessarily.
* It detects and warns about possible malicious sudo code in the PKGBUILDs.
* It disposes of an additional full secured mode for paranoïde people.
<!-- Please don't add direct commands to install pacaur. All users should be familiar with the build process. This will save kitties all around the world. -->
The following binary dependencies need to be installed:
* {{pkg|sudo}} [core]
* {{pkg|expac}} [community]
You can then install {{AUR|cower}} as a dependency, and then {{AUR|pacaur}} itself. Both those packages are available from the AUR. You will have to install them with the [[Arch User Repository|official method]] for installing unsupported packages.
{{Note|All users should be familiar with the build process. You can take this as an opportunity to learn what are the operations that [[AUR helpers]] make automatic.}}
The package {{AUR|pacman-color}} is optional but highly recommended for adding color output support.
Invoking pacaur consists of supplying an operation, any applicable options, and usually one or more targets.
usage:  pacaur <operation> [options] [package(s)]
pacman extension
  -S, -Q          extend pacman operations to the AUR
AUR only
  -s, --search    search AUR repository for matching strings
  -i, --info      view package information -- pass twice for details
  -d, --download  download target(s) -- pass twice to download AUR dependencies
  -m, --makepkg  download and make target(s)
  -y, --sync      download, make and install target(s)
  -k, --check    check for AUR update(s)
  -u, --update    update AUR package(s)
  -v, --version  display version information
  -h, --help      display help information
  --fixbackend    quickly rebuild backend
pacman extension - can be used with the -S, -Ss, -Si, -Sii, -Sw, -Su, -Qu, -Sc, -Scc operations
  -a, --aur      only search, install or clean packages from the AUR
  -r, --repo      only search, install or clean packages from the repositories
  -e, --edit      edit target PKGBUILD -- can be combined with the -d, -m, -y, -u flags
  -c, --clean    clean target(s) build files -- can be combined with the -m, -y, -u flags
  -q, --quiet    show less information for query and search
  --devel        consider AUR development packages upgrade
  --ignore        ignore a package upgrade (can be used more than once)
  --noconfirm    do not prompt for any confirmation
  --noedit        do not prompt to edit files
  --rebuild      always rebuild package
===Userbase target===
'''Two types of users''' are in mind:
* those who prefer to have one single tool to manage AUR and official repositories,
* those who prefer to keep their AUR frontend separate from Pacman.
As such there are '''two sets of commands''':
* commands that wrap the pacman binary (-S, -Ss, -Si, -Sw. -Su, -Qu, -Sc) and extend its functions to the AUR. This behavior can be disabled with the '''fallback''' variable in the config file.
* commands that are AUR specific (-s, -i, -m, -y, -k, -u).
pacaur -Ss ''package'' will search the repo, then the AUR if necessary (fallback enabled).
$ pacaur -Ss expac
community/expac 1-2
    pacman database extraction utility
aur/expac-git 20110324-1 (24)
    pacman database extraction utility
pacaur -Ss ''package'' will be restricted to searching in the repo only, while pacaur -Ssa ''package'' will search the AUR (fallback disabled).
$ pacaur -Ss expac
community/expac 1-2
    pacman database extraction utility
$ pacaur -Ssa expac
aur/expac-git 20110324-1 (24)
    pacman database extraction utility
pacaur -s ''package'' will search the AUR only.
$ pacaur -s expac
aur/expac-git 20110324-1 (24)
    pacman database extraction utility
Here are the available options in the config file:
# /etc/xdg/pacaur/config
# The following options are commented out with their default values listed.
# If you wish to use different values, uncomment and update the values.
#builddir="${BUILDDIR:-$tmpdir}"      # build directory
#editor="${EDITOR:-vi}"                # PKGBUILD editor
#editpkgbuild=true                    # edit PKGBUILD script
#editinstall=true                      # edit install script
#fallback=true                        # pacman fallback to the AUR
#clean=true                            # clean up after package install
#cleandevel=true                      # clean up devel package
#color=false                          # color support via pacman-color
#secure=false                          # enhanced security
See also '''man pacaur'''.
=== Config files ===
Pacaur fully honors pacman and makepkg configuration files, as well as the sudoers and cower config file (if existing).
=== Environment variables ===
Note that pacaur fully honors pacman and makepkg environment variables ({{ic|$BUILDDIR}}, {{ic|$PKGDEST}}, {{ic|$PACMAN}}, ...).
=== Sudo configuration ===
Pacaur is designed to be used with [[sudo]] for minimal password prompting and your {{ic|/etc/sudoers}} should be configured accordingly.
To avoid password prompt timeout (typically if you went grabbing a coffee while waiting the build to finish), disable it in your sudoers:
Defaults passwd_timeout=0
===Host name error===
When checking AUR packages for updates, pacaur outputs a lot of "Couldn't resolve host name" and "Timeout was reached" messages in spite of the internet line working correctly.
* [[General_Recommendations#DNS_speed_improvement|Configure your DNS server]] to improve queries speed. Try using Google primary DNS ( and
* Alternatively, tweak cower's config file to decrease the number of threads used in "MaxThread" variable.
===Using gvim as editor===
When using gvim as editor, gvim opens but the build continues. In the config file, try:
editor="gvim --nofork"
==External Links==
* [http://spyhawk.github.com/pacaur/ Project page]
* [https://bbs.archlinux.org/viewtopic.php?pid=937423 Forum page]
* [https://github.com/Spyhawk/pacaur pacaur's github page]

Latest revision as of 06:14, 5 October 2015

Redirect to: