Justin wrote:Auto removing packages on any OS is dangerous and thus isn't implemented in eopkg.
Auto removing packages is only dangerous when you are doing it wrong. I've never seen any big distro breaking after doing an auto remove, have you?
A typical case for auto remove: LibreOffice. It consists out of single packages, like libreoffice-writer, libreoffice-calc, libreoffice-impress, and so on. But all these packages require libreoffice-common to be installed, it's a dependency. No user will ever install libreoffice-common himself though, as on its own this packet servers no purpose. So no matter what package you install, libreoffice-common gets installed as well. Yet if you remove the installed package again, libreoffice-common stays installed.
An auto-remove function in other distros would see that
- libreoffice-common itself was only installed to satisfy a dependency of another package
- No installed package still requires libreoffice-common
Result: Bye bye package. And this is totally safe.
Justin wrote:There are lots of packages that aren't depended on like bash and if you remove that, the whole system breaks.
- If a package requires bash to run, it should list bash as dependency. Otherwise it would not run on systems that have no bash installed and having bash installed is not a requirement on any Linux system.
- Auto-remove never considers packages as removable, that the user has installed explicitly. Of course, this means the package system must remember why a package was installed (e.g. on user request or just to resolve some dependency).
- Packages installed during system installation would be considered "installed on user request", unless they are only there to satisfy dependencies of other packages. Otherwise running auto-remove after a fresh system install would destroy pretty much all of the system again and I've never seen that happening on other systems.
- There can be a blacklist of non-auto-removable packets containing all the packets that the system considers core and that would break the system itself if being auto removed. I don't know if other systems have such a list but it seems meaningful to me and thus I wouldn't be surprised if they do. Actually you would also check manual removes against that list and warn users if they seem to do something really stupid.
Auto-remove is totally safe on all systems that offer it, so I see no reason why it cannot be safe with Solus. And in the attempt of making a distro as simple as possible, and that seems to be one of the design goals of Solus, it's an important missing feature to aid Linux beginners with package management.