>>>>> On Mon, 21 Aug 2023, konsolebox  wrote:

> This actually allows users to virtually extend an eselect module without
> needing to fork it.  The things people can do are endless.

This isn't what eselect modules were designed for. They are specialised
tools that are supposed to do one thing, and one thing only. It's like
suggesting that a command like cat or mv would need configuration or
some extension mechanism.

Also, given that eselect modules are normally run as root and the damage
that can result from bugs, I'd rather keep things simple, instead of
introducing "endless" possibilities. This approach has worked very well
during the last 18 years.

(If anything, a hook mechanism would look very different from what was
proposed here. First, changing a low-level function like check_do() is
really a no-no, because this function is documented in the eselect
developer guide and third-party modules may rely on it. Second, instead
of executing a separate script for every hook, there would be a file
defining shell functions for all subactions of a given module. But I
haven't thought about any details, because as I said, I don't see much
incentive for such a thing.)

Reply via email to