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

Re: PATCH: _tar, again



Peter Stephenson wrote:

> Minor gripes: in the listing, _long_options doesn't show the / after
> directories inside the archive as my original _tar did (that's why I stuck
> it on the end instead of treating it as a suffix);

I was aware of this, I just thought that the auto-removability was
more interesting. But if you prefer... the patch below changes this.

> _path_files seems to
> have forgotten about noglobdots somehow.

Actually `globdots' was explicitly set, I don't remember why, so the
patch removes the setopts for it.

>  Somehow my _match_pattern isn't
> having an effect on _multi_parts, but I suppose that's my problem.

*Shrug*, works for me...

Bye
 Sven

diff -u oc/Core/_main_complete Completion/Core/_main_complete
--- oc/Core/_main_complete	Tue Mar  9 11:31:45 1999
+++ Completion/Core/_main_complete	Tue Mar  9 11:49:11 1999
@@ -32,7 +32,7 @@
 
 local comp name _comp_correct comax
 
-setopt localoptions nullglob rcexpandparam globdots
+setopt localoptions nullglob rcexpandparam
 unsetopt markdirs globsubst shwordsplit nounset ksharrays
 
 # Special completion contexts after `~' and `='.
diff -u oc/Core/_multi_parts Completion/Core/_multi_parts
--- oc/Core/_multi_parts	Tue Mar  9 11:31:45 1999
+++ Completion/Core/_multi_parts	Tue Mar  9 12:10:34 1999
@@ -143,7 +143,7 @@
     for i in "$matches[@]" ; do
       if [[ "$i" = *${sep}* ]]; then
         compadd -U "$group[@]" "$expl[@]" -i "$IPREFIX" \
-	        -p "$pref" -qS "$sep" -s "$orig" - "${i%%${sep}*}"
+	        -p "$pref" -s "$orig" - "${i%%${sep}*}${sep}"
       else
         compadd -U "$group[@]" "$expl[@]" -i "$IPREFIX" \
 	        -p "$pref" -s "$orig" - "${i%%${sep}*}"
@@ -152,8 +152,8 @@
   else
     for i in "$matches[@]" ; do
       if [[ "$i" = *${sep}* ]]; then
-        compadd -U -i "$IPREFIX" -p "$pref" -s "${sep}${i#*${sep}}" \
-	        "$group[@]" "$expl[@]" -M "r:|${sep:q}=*" - "${i%%${sep}*}"
+        compadd -U -i "$IPREFIX" -p "$pref" -s "${i#*${sep}}" \
+	        "$group[@]" "$expl[@]" -M "r:|${sep:q}=*" - "${i%%${sep}*}${sep}"
       else
         compadd -U "$group[@]" "$expl[@]" -i "$IPREFIX" -p "$pref" - "$i"
       fi
diff -u oc/Core/_path_files Completion/Core/_path_files
--- oc/Core/_path_files	Tue Mar  9 11:31:45 1999
+++ Completion/Core/_path_files	Tue Mar  9 11:49:15 1999
@@ -22,7 +22,7 @@
 local tmp1 collect tmp2 suffixes i ignore matchflags opt group sopt pats gopt
 local addpfx addsfx expl orig ostr nm=$compstate[nmatches] menu
 
-setopt localoptions nullglob rcexpandparam globdots extendedglob
+setopt localoptions nullglob rcexpandparam extendedglob
 unsetopt markdirs globsubst shwordsplit nounset
 
 prepaths=('')

--
Sven Wischnowsky                         wischnow@xxxxxxxxxxxxxxxxxxxxxxx



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