![](https://secure.gravatar.com/avatar/9820b5956634e5bbad7f4ed91a232822.jpg?s=120&d=mm&r=g)
chris wrote:
I've submitted a patch for an uninstall feature here:
Hi Chris, Yes, I saw it. Unfortunately, it is a setuptools extension, and I don't want to use setuptools. I also want something which may be integrated by distutils at some point.
Currently it works by creating an installed_files.log file in an egg on install. This file is used during uninstall (-r option) to remove all files associated with an egg. If an egg was installed before this patch was applied, the only things missed will be external scripts.
It will also do some dependency checking. If the package being removed is depended upon by something else, it will warn the user (showing what needs that package). If the package being removed has a dependency not needed by anything else, it presents the user with the option of removing that dependency as well. Also, entries from easy_install.pth are removed.
Do you think it would be possible to refactor it to split the distutils/setuptools parts ? I could do it myself, obviously, but I don't know anything about setuptools internals. cheers, David