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

Re: When _alternative separates the options?



On Mon, 21 Oct 2019 at 12:06, Oliver Kiddle <okiddle@xxxxxxxxxxx> wrote:
>
> Sebastian Gniazdowski wrote:
> > _alternative 'snippets:downloaded snippets:compadd -a - snippets' \
> >      'snippets:already loaded snippets:compadd -a - snippets_alreadyld' \
> >      'files:file:_files' && \
> >          ret=1
> >
> > The "downloaded snippets" and "already loaded snippets" will be
> > merged. Is there a way to separate those?
>
> Try giving them a different tag. Otherwise they will end up in the same
> group. So something like:
>
>   _alternative \
>     'downloaded-snippets:downloaded snippet:compadd -a - snippets' \
>     'already-loaded-snippets:already loaded snippet:compadd -a - snippets_alreadyld'
>     ...
>
> As an aside, the normal zsh convention is plural form for the tags and
> singular for the group descriptions.

Thanks, it helped.

-- 
Sebastian Gniazdowski
News: https://twitter.com/ZdharmaI
IRC: https://kiwiirc.com/client/chat.freenode.net:+6697/#zplugin
Blog: http://zdharma.org



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