[plug] Removing old package dependencies with apt/dpkg [derived from: apt-get sources.list]

Anthony J. Breeds-Taurima tony at cantech.net.au
Thu Oct 3 13:04:44 WST 2002


On Thu, 3 Oct 2002 ryan at is.as.geeky.as wrote:

> In reference to all this apt talk, I think I vaguely recall someone telling
> me this following feature question doesn't exists and that it would be
> 'nice' to have ... I could be mistaken though:
> 
> The question:
> =============
> Is there a way to 'apt-get remove xyz' and have it remove all dependant
> packages that are no longer needed or dpkg -r/--purge with the same effect -
> ie. remove the packages that were installed along with that package xyz as
> dependencies if they are no longer depended upon by any other package?
> 
> If not then I'm sure a few joint efforts between apt and dpkg in a shell
> script could achieve something of the sort?

It's not an exact fit BUT deporphin will generate a list of all packages
upon which no other package depends.  If you're really game

apt-get remove --purge `deborphin`

Yours Tony

   Jan 22-25 2003           Linux.Conf.AU            http://linux.conf.au/
		  The Australian Linux Technical Conference!



More information about the plug mailing list