Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

RE: Function installation



>
> * --enable-fndir=directory allows you to specify a function installation
>   directory; default is ${datadir}/zsh-fns, almost certainly
>   ${prefix}/share/zsh-fns
>

Peter, are you so fond of cryptic names? Why not simply {datadir}/zsh or, at
least, ${datadir}/zsh/functions ? (In hope, that may be some more stuff will
evtl go into base dir).

> * The given directory is compiled as the default value for $fpath/$FPATH
>
> * `make install' or `make install.fns' will install all functions from
>   under Completion and Functions into that directory, `make uninstall' or
>   `make uninstall.fns' will delete them.
>

May I argue that? Most functions in Functions are hardly more than examples;
some of them are outdated (who needs cdmatch/multi_comp with new
completion?). I believe, this choice should be left to those, who maintains
ZSH distributions (RPMs), and it should default to off for source install.

The same with new completion stuff. The files, that must be installed (if at
all) are Core, Base and (probably) Builtins. Without them new completion
won't run. But again, I don't want to see a bunch of completions for GNUish
systems here - I don't use GNU tools.

So. I'd prefer the way to separately install Completion and Functions, with
Functions being off by default. And to select, what part is installed.

Peter, what about something like this:

use variables like FUNCTIONS_INCLUDE and/or FUNCTIONS_EXCLUDE. They could be
initialized by configure; and then I could set FUNCTIONS_EXCLUDE='Commands/*
User/*' FUNCTIONS_INCLUDE='Users/_configure' to get only this one installed?


> * --disable-fndir or --enable-fndir=no turns off both installation of
>   functions and the default $fpath/$FPATH
>

See above.



New Completion Intialisation. Again.

Now, that we (almost) have the stuff there in fpath automagically, please,
consider once again making compinit a function. It would provide for
system-independent rc files - instead of figuring out, where the hell these
functions are placed here, you simply write compinit - and you're done.

I would even opt for a simple builtin that simply sources this file (may be,
under different name to avoid confusion). That file could be then placed in
different dir - let's say, smply ${datadir}/zsh, so, that it won't mess up
in $fpath.

/andrej




Messages sorted by: Reverse Date, Date, Thread, Author