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

Re: PATCH: Make _xset complete more helpfully



On May 12,  6:59pm, Mikael Magnusson wrote:
} Subject: PATCH: Make _xset complete more helpfully
}
} Looking into it now, this seems to be the fix, but I'm not sure I
} understand why. Is it simply wrong to give words not starting with a -
} or + to _describe when you pass -o?

As usual, the way to find out is to try it both ways and compare the
output of _complete_debug.

In this case _describe -o bails out at line 29:

     27 [[ "$_type$_noprefix" = options && ! -prefix [-+]* ]] && \
     28     zstyle -T ":completion:${curcontext}:options" prefix-needed &&
     29         return 1

I'm not sure it's correct for it to entirely punt when prefix-needed
is not defined.  Probably the right thing would be to assume a default
value instead ... but I don't really know.

-- 



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