Home

Awesome

ZSH Arch Linux plugin

This plugin adds some aliases and functions to work with Arch Linux.
Based on oh-my-zsh archlinux plugin

Installation

Zgenom

Add zgenom load Junker/zsh-archlinux to your .zshrc and run source ~/.zshrc

Antigen

Add antigen bundle Junker/zsh-archlinux@main to your .zshrc and run source ~/.zshrc

Znap

Add znap source Junker/zsh-archlinux to your .zshrc and run source ~/.zshrc

Sheldon

Run this in your terminal emulator:

sheldon add --github 'Junker/zsh-archlinux' zsh-arch
sheldon lock
sheldon source

Without using a framework

  1. git clone git@github.com:Junker/zsh-archlinux.git
  2. Add source /path/to/repository/archlinux.plugin.zsh to your .zshrc file.

Features

Pacman

AliasCommandDescription
pacinsudo pacman -SInstall packages from the repositories
pacndepssudo pacman -SddInstall a package or packages without dependencies
pacinssudo pacman -UInstall a package from a local file
pacinsdsudo pacman -S --asdepsInstall packages as dependencies of another package
pacleansudo pacman -ScClean out old and unused caches and packages
paclocpacman -QiDisplay information about a package in the local database
paclocspacman -QsSearch for packages in the local database
paclrsudo pacman -SccRemove all files from the cache
paclsorphanssudo pacman -QdtList all orphaned packages
pacmirsudo pacman -SyyForce refresh of all package lists after updating mirrorlist
pacresudo pacman -RRemove packages, keeping its settings and dependencies
pacremsudo pacman -RnsRemove packages, including its settings and dependencies
pacreppacman -SiDisplay information about a package in the repositories
pacrepspacman -SsSearch for packages in the repositories
pacrmorphanssudo pacman -Rs $(pacman -Qtdq)Delete all orphaned packages
pacupdsudo pacman -SyUpdate and refresh local package, ABS and AUR databases
pacupgsudo pacman -SyuSync with repositories before upgrading packages
pacfileupgsudo pacman -FyDownload fresh package databases from the server
pacfilespacman -FSearch package file names for matching strings
paclspacman -QlList files in a package
pacownpacman -QoShow which package owns a file
upgrade¹sudo pacman -SyuSync with repositories before upgrading packages
FunctionDescription
pacdisownedList all disowned files in your system
paclistList all explicitly installed packages with a description
pacmanallkeysGet all keys for developers and trusted users
pacmansignkeysLocally trust all keys passed as parameters
pacwebOpen the website of an ArchLinux package

Note: paclist used to print packages with a description which are (1) explicitly installed and (2) available for upgrade. Due to flawed scripting, it also printed all packages if no upgrades were available. Use pacman -Que instead.

AUR helpers

Aura

AliasCommandDescription
aucleansudo aura -ScClean out old and unused caches and packages
auclrsudo aura -SccRemove all files from the cache
auinsudo aura -SInstall packages from the repositories
aurinsudo aura -AInstall packages from the repositories
auinssudo aura -UInstall a package from a local file
auinsdsudo aura -S --asdepsInstall packages as dependencies of another package (repositories only)
aurinsdsudo aura -A --asdepsInstall packages as dependencies of another package (AUR only)
aulocaura -QiDisplay information about a package in the local database
aulocsaura -QsSearch for packages in the local database
aulsaura -QqlList all files owned by a given package
aulstaura -QeList installed packages including from AUR (tagged as "local")
aumirsudo aura -SyyForce refresh of all package lists after updating mirrorlist
aurphsudo aura -OjRemove orphans using aura
auownaura -QqoSearch for packages that own the specified file(s)
auresudo aura -RRemove packages, keeping its settings and dependencies
auremsudo aura -RnsRemove packages, including its settings and unneeded dependencies
aurepaura -SiDisplay information about a package in the repositories
aurrepaura -AiDisplay information about a package from AUR
aurepsaura -As --bothSearch for packages in the repositories and AUR
aurasaura -As --bothSame as above
auupdsudo aura -SyUpdate and refresh local package, ABS and AUR databases
auupgsudo sh -c "aura -Syu && aura -Au"Sync with repositories before upgrading all packages (from AUR too)
aususudo sh -c "aura -Syu --no-confirm && aura -Au --no-confirm"Same as auupg, but without confirmation
upgrade¹sudo aura -SyuSync with repositories before upgrading packages
FunctionDescription
auownloc fileDisplay information about a package that owns the specified file(s)
auownls fileList all files owned by a package that owns the specified file(s)

Pacaur

AliasCommandDescription
paccleanpacaur -ScClean out old and unused caches and packages
pacclrpacaur -SccRemove all files from the cache
painpacaur -SInstall packages from the repositories
painspacaur -UInstall a package from a local file
painsdpacaur -S --asdepsInstall packages as dependencies of another package
palocpacaur -QiDisplay information about a package in the local database
palocspacaur -QsSearch for packages in the local database
palstpacaur -QeList installed packages including from AUR (tagged as "local")
pamirpacaur -SyyForce refresh of all package lists after updating mirrorlist
paorphpacaur -QtdRemove orphans using pacaur
parepacaur -RRemove packages, keeping its settings and dependencies
parempacaur -RnsRemove packages, including its settings and unneeded dependencies
pareppacaur -SiDisplay information about a package in the repositories
parepspacaur -SsSearch for packages in the repositories
paupdpacaur -SyUpdate and refresh local package, ABS and AUR databases
paupgpacaur -SyuaSync with repositories before upgrading all packages (from AUR too)
pasupacaur -Syua --no-confirmSame as paupg, but without confirmation
upgrade¹pacaur -SyuSync with repositories before upgrading packages

Paru

AliasCommandDescription
parcleanparu -ScClean out old and unused caches and packages
parclrparu -SccRemove all files from the cache
parinparu -SInstall packages from the repositories
parinsparu -UInstall a package from a local file
parinsdparu -S --asdepsInstall packages as dependencies of another package
parlocparu -QiDisplay information about a package in the local database
parlocsparu -QsSearch for packages in the local database
parlstparu -QeList installed packages including from AUR (tagged as "local")
parmirparu -SyyForce refresh of all package lists after updating mirrorlist
parreparu -RRemove packages, keeping its settings and dependencies
parremparu -RnsRemove packages, including its settings and unneeded dependencies
parrepparu -SiDisplay information about a package in the repositories
parrepsparu -SsSearch for packages in the repositories
parupdparu -SyUpdate and refresh local package, ABS and AUR databases
parupgparu -SyuSync with repositories before upgrading packages
upgrade¹paru -SyuSync with repositories before upgrading packages

Trizen

AliasCommandDescription
trconftrizen -CFix all configuration files with vimdiff
trcleantrizen -ScClean out old and unused caches and packages
trclrtrizen -SccRemove all files from the cache
trintrizen -SInstall packages from the repositories
trinstrizen -UInstall a package from a local file
trinsdtrizen -S --asdepsInstall packages as dependencies of another package
trloctrizen -QiDisplay information about a package in the local database
trlocstrizen -QsSearch for packages in the local database
trlsttrizen -QeList installed packages including from AUR (tagged as "local")
trmirtrizen -SyyForce refresh of all package lists after updating mirrorlist
trorphtrizen -QtdRemove orphans using yaourt
trretrizen -RRemove packages, keeping its settings and dependencies
trremtrizen -RnsRemove packages, including its settings and unneeded dependencies
trreptrizen -SiDisplay information about a package in the repositories
trrepstrizen -SsSearch for packages in the repositories
trupdtrizen -SyUpdate and refresh local package, ABS and AUR databases
trupgtrizen -SyuaSync with repositories before upgrading all packages (from AUR too)
trsutrizen -Syua --no-confirmSame as trupg, but without confirmation
upgrade¹trizen -SyuSync with repositories before upgrading packages

Yay

AliasCommandDescription
yaconfyay -PgPrint current configuration
yacleanyay -ScClean out old and unused caches and packages
yaclryay -SccRemove all files from the cache
yainyay -SInstall packages from the repositories
yainsyay -UInstall a package from a local file
yainsdyay -S --asdepsInstall packages as dependencies of another package
yalocyay -QiDisplay information about a package in the local database
yalocsyay -QsSearch for packages in the local database
yalstyay -QeList installed packages including from AUR (tagged as "local")
yamiryay -SyyForce refresh of all package lists after updating mirrorlist
yaorphyay -QtdRemove orphans using yay
yareyay -RRemove packages, keeping its settings and dependencies
yaremyay -RnsRemove packages, including its settings and unneeded dependencies
yarepyay -SiDisplay information about a package in the repositories
yarepsyay -SsSearch for packages in the repositories
yaupdyay -SyUpdate and refresh local package, ABS and AUR databases
yaupgyay -SyuSync with repositories before upgrading packages
yasuyay -Syu --no-confirmSame as yaupg, but without confirmation
upgrade¹yay -SyuSync with repositories before upgrading packages

Rua (ONLY WORKS WITH AUR PACKAGES)

AliasCommand
ruinrua installInstalls a package or packages
ruserua searchSearches the aur for packages
rushrua shellcheckRuns shellcheck on a PKGBUILD, essentially debugging it
rutarrua tarcheckRuns rua checks on a prebuilt pkg tarball
ruberua builddirBuild a package from a directory and subdirectories
rubeoffrua builddir --offlineSame as rube, but builds in offline mode
upgrade¹rua upgradeUpgrades all installed AUR packages

<span id="f1">¹</span> The upgrade alias is set for all package managers. Its value will depend on whether the package manager is installed, checked in the following order:

  1. yay
  2. paru
  3. trizen
  4. pacaur
  5. aura
  6. pacman
  7. aura

Contributors