[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How to check that if a package is installed?

Andrei Popescu wrote:
> You don't even need the 
> 'dpkg -l' is fine as well, if used properly ;)
> $ dpkg -l tofrodos
> No packages found matching tofrodos.

However that doesn't handle packages that had been installed but are
now removed but not purged leaving configuration files behind.

To find packages installed and then removed but not purged:

  grep-status -F Status 'deinstall ok config-files' -ns Package

Pick any of the ones there on the list for your machine (if any) and
then run dpkg -l against it.

  $ dpkg -l network-manager
  rc   network-manager   0.8.1-3   network management framework daemon
  $ echo $?


P.S. grep-status is provided in the dctrl-tools package.

Attachment: signature.asc
Description: Digital signature

Reply to: