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

Re: Problem with 'env' completion (was: Using another command's completion function with an alias)



On Thu, 12 Nov 2009, Benjamin R. Haskell wrote:

> Upon further tinkering, I think this might (additionally) be a problem 
> with the completion for 'env'...
>
> It doesn't seem to like more than one '-u' argument[...]

Patch attached.

Best,
Ben
Index: Completion/Unix/Command/_env
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Unix/Command/_env,v
retrieving revision 1.1
diff -u -r1.1 _env
--- Completion/Unix/Command/_env	13 Apr 2006 02:46:50 -0000	1.1
+++ Completion/Unix/Command/_env	12 Nov 2009 19:59:46 -0000
@@ -3,7 +3,7 @@
 if _pick_variant gnu=Free\ Soft unix --version; then
   _arguments \
     '(--ignore-environment -i)'{-i,--ignore-environment}'[start with empty environment]' \
-    {-u,--unset=}':env var to remove:compadd ${(k)parameters[(R)*export*]}' \
+    '*'{-u,--unset=}':env var to remove:compadd ${(k)parameters[(R)*export*]}' \
     '--help[help]' \
     '--version[version]' \
     '*::arguments: _normal'


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