Datasheet

90
Part I The Fundamentals
Purging configuration files for vim ...
hostname:~# ls /etc/vim/
ls: /etc/vim/: No such file or directory
hostname:~#
apt-get again asked us for permission to perform this operation; it indicated it was
purging the package by appending an asterisk to the package’s name. The final
ls
command verifies that that directory is in fact now gone. Now that vim is purged, if
you reinstall it, its default configuration file will be installed freshly again.
Note, however, that
apt-get didn’t remove libgpmg1, which was installed along-
side
vim to satisfy a dependency. If packages are installed as dependencies of
another package,
apt-get will not look to see whether they are still needed when
you uninstall the original package and will simply leave them there. Now take a look
at how
aptitude deals with that scenario.
Removing and purging packages using aptitude
Let’s get rid of mutt first, which we installed earlier via aptitude:
hostname:~# aptitude remove mutt
Reading Package Lists... Done
Building Dependency Tree
Reading extended state information... Done
The following packages are unused and will be REMOVED:
libidn11 libncursesw5 libsasl2 libsasl2-modules mime-support
The following packages will be REMOVED:
mutt
0 packages upgraded, 0 newly installed, 6 to remove and 61 not upgraded.
Need to get 0B of archives. After unpacking 5788kB will be freed.
Do you want to continue? [Y/n/?] y
Writing extended state information... Done
(Reading database ... 17519 files and directories currently installed.)
Removing mutt ...
Removing libidn11 ...
Removing libncursesw5 ...
Removing libsasl2-modules ...
Removing libsasl2 ...
Removing mime-support ...
Reading Package Lists... Done
Building Dependency Tree
Reading extended state information... Done
hostname:~#
You can purge a package on the command-line with aptitude by running the
command aptitude purge packagename. Note the difference between this
and apt-get, which accepts purge as a double-dash option to remove.
Note
09_576445 ch04.qxd 7/5/05 3:10 PM Page 90