about summary refs log tree commit diff
diff options
context:
space:
mode:
authorClint Adams <clint@users.sourceforge.net>2007-08-18 04:23:18 +0000
committerClint Adams <clint@users.sourceforge.net>2007-08-18 04:23:18 +0000
commitb37f52b8841f6a21a898e8f6e5acb7021ea94853 (patch)
treeee5022dd0fe605fc7f0d22f8875550025e53fd73
parent0a607f5eefec38cc7ef625f1692bd1d12e969f90 (diff)
downloadzsh-b37f52b8841f6a21a898e8f6e5acb7021ea94853.tar.gz
zsh-b37f52b8841f6a21a898e8f6e5acb7021ea94853.tar.xz
zsh-b37f52b8841f6a21a898e8f6e5acb7021ea94853.zip
23775: restore completion of devicename=filename pairs after -Z and -M.
-rw-r--r--ChangeLog5
-rw-r--r--Completion/Unix/Command/_growisofs19
2 files changed, 21 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 031da9e4d..b22267c78 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-08-18  Clint Adams  <clint@zsh.org>
+
+	* 23775: Completion/Unix/Command/_growisofs:
+	restore completion of devicename=filename pairs after -Z and -M.
+
 2007-08-16  Peter Stephenson  <pws@csr.com>
 
 	* 23764: Doc/Zsh/calsys.yo, Functions/Calendar/calendar,
diff --git a/Completion/Unix/Command/_growisofs b/Completion/Unix/Command/_growisofs
index fea7091f5..09a04c6e4 100644
--- a/Completion/Unix/Command/_growisofs
+++ b/Completion/Unix/Command/_growisofs
@@ -1,5 +1,8 @@
 #compdef mkisofs growisofs
 
+local context state line
+typeset -A opt_args
+
 declare -a find_options
 
 find_options=(
@@ -181,8 +184,8 @@ else
 
   if [[ $service == growisofs ]]; then
     growisofs_options=(
-      '-Z[burn an initial session to the selected device]:device:_files -g "*(%,@)"'
-      '-M[merge a session with an existing one on the selected device]:device:_files -g "*(%,@)"'
+      '-Z[burn an initial session to the selected device]:device:->devimg'
+      '-M[merge a session with an existing one on the selected device]:device:->devimg'
       '-dvd-compat[provide maximum compatibility with DVD-ROM/Video]'
       '-dry-run[do everything up to the actual burning process]'
       '-overburn[allow overburning of the media]'
@@ -328,5 +331,15 @@ else
     '(- *)-help[display help message]' \
     '(- *)-version[display version information]' \
     $growisofs_options \
-    '*:pathspec:_mkisofs_pathspec'
+    '*:pathspec:_mkisofs_pathspec' && return 0
+
+    case "$state" in
+      (devimg)
+      if compset -P \*=; then
+        _files
+      else
+        _files -g "*(%,@)"
+      fi
+      ;;
+      esac
 fi