On Sep 18, 8:34am, Sebastian Gniazdowski wrote:
}
} are there any pitfalls about functions declared in this way instead of
} using autoload and separate files? Is this enough to have plugin for
} e.g. antigen?
There aren't any pitfalls to this, except that the file has to be
sourced (i.e., all the functions fully defined in shell memory) unless
there is a single entry-point function whose name can be the same as
the basename of the file, and thereby trigger loading the whole thing.
E.g. the _git file that handles completion for all the git subcommands
has a whole slew of helper functions, none of which are loaded until
an attempt to complete for "git" is done, at which time the _git entry
point function loads all of them.