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

Re: compinit prints out last functions



On 9/7/07, Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx> wrote:

The first thing to try is "which compinit" to find out whether compinit
is set to the correct function, and if not (which is probably the case)
what it is.

$ which compinit
compinit () {
        # undefined
        builtin autoload -XUz
}

I don't even know enough to know if that's right or not, but I will assume that is it.

Next you need to find out how compinit is being defined to what it is.
Start "zsh -x"; you'll get lots of output (if you like, use "script zsh
-x" to copy it to a file) and somewhere in there should be a reference
to how compinit is being defined.  Normally it will be something like
"autoload -U compinit".  (If the -U is missing, something funny could be
happening with aliases.)

+/cygdrive/h/.zshrc:2&gt; autoload -U compinit
+/cygdrive/h/.zshrc:3&gt; compinit -i
+compinit:70&gt; emulate -L zsh
+compinit:71&gt; setopt extendedglob
[....]

If all that seems OK, look for the compinit in your fpath:

ls $^fpath/compinit(N)

and see what's in it.

First runable lines look like:

emulate -L zsh
setopt extendedglob

Which is what zsh is running on startup (from #2).

Except for #1, everything seems fine.  I don't know about to say anything about the "which compinit" results, though.
--
Mike Hostetler
http://mike.hostetlerhome.com/



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