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

java completion wrong?



java hello <tab> completes commands instead of files, likewise for
java -jar hello.jar <tab>, the following patch seems to fix it, but I
don't know that much about java syntax so maybe it breaks something
else.

Index: Completion/Unix/Command/_java
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Unix/Command/_java,v
retrieving revision 1.16
diff -p -u -d -r1.16 _java
--- Completion/Unix/Command/_java	8 Jun 2005 12:45:35 -0000	1.16
+++ Completion/Unix/Command/_java	1 May 2007 17:44:58 -0000
@@ -45,7 +45,7 @@ java)
    '-help[print help message]' \
    '(- 1)-jar[specify a program capsulated as jar]:jar:_files -g
\*.jar\(-.\)' \
    '(-):class:_java_class -m main ${(kv)opt_args[(i)(-classpath|-cp)]}' \
-    '*::args: _normal' \
+    '*::args: _files' \
     && return 0
  ;;


--
Mikael Magnusson



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