Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How to make pacman (archlinux's package manager) to not reinstall when the package already installed

 pacman -S packagename    # install and reinstall if exists
share|improve this question
up vote 20 down vote accepted

Use the --needed option to skip reinstall of existing packages when you Sync (-S).

If a package in the list is already installed on the system, it will be reinstalled even if it is already up to date. This behavior can be overridden with the --needed option.

share|improve this answer

I have been thinking that the pacman -Su xxx will do that But actually it still will reinstall the updated-installed xxx pacakge the --needed will do that after my testing, as for the non-updated installed package need to be tested later

share|improve this answer
This duplicates another answer and adds no new content. Please don't post an answer unless you actually have something new to contribute. – DavidPostill Jul 4 '15 at 15:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .