Pacman

Instalar pacote existente, ou lista separada por espaço Install single package (or space-separated list)

# pacman -S [pacoteira]

Procurar por ‘pacoteira’ nos repos disponiveis Search for a string in available repos

# pacman -Ss [pacoteira]

Atualização completa do sistema (–no-confirm vai executar automatico com as respostas padrão) Full system upgrade (–no-confirm will override questions to default answers)

# pacman -Syu

Limpar pacotes antigos do cache do Pacman (-Scc para apagar TODOS os pacotes) Purge old packages from Pacman cache (use -Scc to purge ALL packages)

# pacman -Sc

Atualizar os repos do Pacman (-Syy para forçar a atualização) Update Pacman Repos (use -Syy to force update)

# pacman -Sy

List packages in a given [repo]

# pacman -Sl [repo]

Discover to which repo a given [pacoteira] belongs

# pacman -Sl | grep [pacoteira]

Custom Repo – use file name to add / use pkg name to remove

# repo-add /path/to/repo.db.tar.gz /path/to/package-1.0-1-x86_64.pkg.tar.xz
# repo-add /path/to/repo.db.tar.gz /path/to/*.pkg.tar.xz
# repo-remove /path/to/repo.db.tar.gz pkgname

Pacman-Key

# pacman-key --init
# pacman-key --populate [keyrings installed at /usr/share/pacman/keyrings]
# pacman-key --refresh--keys
  • pacman-key –list-keys
  • pacman-key –list-sigs

If the key is found on a keyserver, import it with:

# pacman-key –recv-keys keyid

If otherwise a link to a keyfile is provided, download it and then run:

# pacman-key --add /path/to/downloaded/keyfile

It is recommended to verify the fingerprint, as with any master key or any other key you are going to sign:

$ pacman-key –finger keyid

Finally, you must locally sign the imported key:

# pacman-key –lsign-key keyid

Wroking example:

# pacman -Syy --noconfirm pacman-mirrorlist archlinux-keyring haveged
# pacman-key --init
# pacman-key --populate
# pacman-key --recv-keys B0391223A038F085
# pacman-key --lsign-key B0391223A038F085

# cat << _EOF_ >> /etc/pacman.conf

[cryptostratus]
Server = https://archlinux.cryptostratus.net/\$arch
_EOF_

# pacman -Sy && pacman -S fake-hwclock-git --noconfirm

pacman -Q | grep [pacoteira] pacman -Qi [pacoteira] pacman -Ql [pacoteira] pacman -Qo [pacoteira] pacman -Qm pacman -Qn pacman -Qtd

pacman -R [pacoteira] pacman -Rs [pacoteira] pacman -Rns [pacoteira] pacman -Rns $(pacman -Qtdq)