removing packages and dependencies

Derek Broughton news at pointerstop.ca
Mon Oct 2 17:38:22 BST 2006


Christopher J. Bottaro wrote:

> How to I remove package A and all the packages that package A depends on
> that aren't being used by other packages.
> 
> This is different that "apt-get remove package_A" which removes package A
> and all packages that depend on package A.

The short answer is: not easily.  If you do all your installs with aptitude,
then, when aptitude removes a package, it removes all packages no longer
needed - but they have to have been installed with aptitude in the first
place.  Or you can manually go through all your packages using "aptitude
markauto PACKAGE" for the ones that you want removed if they aren't
needed - then in future just use aptitude.

What I originally did was iirc "aptitude markauto ~Nlib*".  Careful though -
it will want to remove a few lib* packages that really shouldn't be marked
as automatic.  That gets rid of the majority of packages that are only
dependencies, but I still put in a lot of time checking every single
package.  
-- 
derek 




More information about the kubuntu-users mailing list