Web lists-archives.com

Re: FHS: Where to store user specific plugins / code

On Wed, 2018-02-28 at 18:14:17 -0500, Marvin Renich wrote:
> * Ian Jackson <ijackson@xxxxxxxxxxxxxxxxxxxxxx> [180228 17:45]:
> > Georg Faerber writes ("FHS: Where to store user specific plugins / code"):
> > > Currently, we allow users to run / execute their own plugins, stored in
> > > /etc/schleuder/plugins. Obviously, that's not the right place, as /etc
> > > is for config files, not executable code. We would like to fix this, but
> > > are unsure which location to offer. The (empty) directory would be
> > > provided by the package, but the (possible) content would be provided by
> > > the user.
> > > 
> > > Therefore, I'm wondering what's the correct place: Would
> > > /usr/local/lib/schleuder/plugins be sensible? If not, any other place
> > > which is more suitable?

> > Do plugins do something which people might not want if present, and
> > not configured ?  If so then perhaps you want a thing a bit like the
> > apache mods-enabled scheme: a link farm.
> > 
> > If not, then if it's easy to do I would load all plugins in
> >     /usr/local/lib/schleuder/plugins
> >     /usr/lib/schleuder/plugins
> > (former masking the latter with for with the same name)
> If a user get to install his/her own plugins, they should go in the
> user's home directory, e.g. /home/user/.config/scheduler/plugins/.

Definitely not under .config, for the same reasons it would be wrong
for those to go under /etc.

From the XDG Base Dir spec, the thing that's somewhat closest is
$XDG_DATA_HOME with a default of $HOME/.local/share. But that spec is
lacking in many places, and a missing .local/bin and .local/lib are
among those.

There are the logical extensions for those at
<https://theos.kyriasis.com/~kyrias/basedir-spec.html>, but
unfortunately nothing seems to refer to XDG_LIB_HOME on sources.d.o. :(