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

curtag (Re: can't run _email-mutt)



Just got a chance to look at this ...

On Jun 6,  6:42pm, Oliver Kiddle wrote:
} 
} Has anyone got any ideas on how to narrow the context for the plugin
} tag-order. Currently, if you want to specify a list of plugins as a
} global setting, you need a context like ':completion:*'. That's not
} nice  but the best alternative is listing commands:
} ':completion:*:(mailx|Mail|mutt|mush|ali|netscape):*'

One possibility would be for _email_addresses to call

  _tags -C email-addresses email-$plugins

which would make the context look like

  :completion:*:*:*:email-addresses:*

} Ideally, _tags should allow me to put 'email-addresses' in as a tag. It
} should perhaps use $curtag.

I'm not sure how $curtag would apply in this case, because it's not set
until _requested or _wanted calls _all_labels from inside the _tags loop?
Or are we talking about nested _tags loops here, which is already a bit
of a sticky wicket?

It's entirely possible that there's some subtlety I'm missing.

On a more general note, though, it would appear that $curtag is rather
under-utilized.  By a quick grep I count about 15 functions that use both
_tags and zstyle without reference to $curtag.  _email_addresses is the
only one that seems to use it as it was intended.



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