Skip to content

Instantly share code, notes, and snippets.

@MadanBhandari
Last active January 30, 2020 07:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MadanBhandari/e59a39a0427389a206a51aae2759533f to your computer and use it in GitHub Desktop.
Save MadanBhandari/e59a39a0427389a206a51aae2759533f to your computer and use it in GitHub Desktop.
pacman commands

update the system

sudo pacman -Syu

update the database

sudo pacman -Syy

install package

from pacman repo

sudo pacman -S package_name

from local package

sudo pacman -U /path/to/the/package

remove package

package only

sudo pacman -R

package and those of its dependencies that aren’t needed by any other application

sudo pacman -Rs

package, avoid orphaned dependencies and erase its global configuration

sudo pacman -Rns package_name

Info about an installed package:

pacman -Qi package_name

Queries the repo about a package:

pacman -Ss package_name

Queries the repo about a packages, and all that depend on it:

pacman -Sii package_nam

List Installed Packages that are not in the Official Repositories:

pacman -Qm

Pacman is completely broken! How do I reinstall it?

sudo tar -xwvpf <i>package_name-version.tar.xz</i> -C / --exclude .PKGINFO --exclude .INSTALL

More info :: http://wiki.archlinux.org/index.php/Pacman

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment