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

Re: purge packages already removed



Anthony Campbell <ac@acampbell.org.uk> writes:
> On 21 Oct 2002, Sandip P Deshmukh wrote:
>> one thing i missed out on was that instaed of purging the packages, i 
>> removed them. if i understand correctly, it means that the configuration 
>> and other files will be on the system still.

(Just the package's declared configuration files, which will generally
all be under /etc.)

>> now, i will like to purge packages i have already removed. this will 
>> make sure that the configuration files will also be deleted/ gone.
>> 
>> is there a way in which it can be done?
>
> I generally just do dpkg --purge <foo.deb>. I expect you could do it in
> aptitude too but I'm pretty new to that.

Packages with "c" in the first column in the aptitude display have
only conffiles on the system; pressing '_' will purge them (same as in
dselect, incidentally).  Searching for '~c' in aptitude will find
packages in this state.

If you really really want to do things from the command line, you can
install the grep-dctrl package and then run

  grep-status -e -FStatus -sPackage 'deinstall.*config'

(Looking at the results, though, grepping for just 'deinstall' might
work, which implies that this might work, too:

  dpkg --get-selections | awk '$2 == "deinstall" { print $1 }'

Certainly, it at least prints a list of package names.)

-- 
David Maze         dmaze@debian.org      http://people.debian.org/~dmaze/
"Theoretical politics is interesting.  Politicking should be illegal."
	-- Abra Mitchell



Reply to: