summary refs log tree commit diff
diff options
context:
space:
mode:
authorDaniel Shahaf <danielsh@apache.org>2019-12-03 12:27:13 +0000
committerDaniel Shahaf <danielsh@apache.org>2019-12-03 12:27:13 +0000
commit06dddd0b98da9fa285573b1a6e1a0ecc2d6c6bd4 (patch)
tree315ee76a9d4badc27ed3e13612d5730990de8642
parent61262ae2821d375929bd418b6acc8d253bfb2faa (diff)
downloadzsh-06dddd0b98da9fa285573b1a6e1a0ecc2d6c6bd4.tar.gz
zsh-06dddd0b98da9fa285573b1a6e1a0ecc2d6c6bd4.tar.xz
zsh-06dddd0b98da9fa285573b1a6e1a0ecc2d6c6bd4.zip
Revert "44904: _subversion: Complete multiple comma-separated arguments to --show-item=<TAB>."
This reverts commit b06117ad21ce8be928e64700f34f7610d45c738a.

Reverted upstream in r1870750.
-rw-r--r--ChangeLog5
-rw-r--r--Completion/Unix/Command/_subversion9
2 files changed, 2 insertions, 12 deletions
diff --git a/ChangeLog b/ChangeLog
index a2b2f3073..6245c976a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -96,11 +96,6 @@
 	* unposted (salsa.debian.org MR!1): Completion/Unix/Command/_ip:
 	Complete the -brief option
 
-2019-11-09  Daniel Shahaf  <d.s@daniel.shahaf.name>
-
-	* 44904: Completion/Unix/Command/_subversion: Complete multiple
-	comma-separated arguments to --show-item=<TAB>.
-
 2019-11-08  Daniel Shahaf  <d.s@daniel.shahaf.name>
 
 	* unposted: Doc/Zsh/compsys.yo: _values: Use the formal
diff --git a/Completion/Unix/Command/_subversion b/Completion/Unix/Command/_subversion
index 2ce43a0cd..a1e9109de 100644
--- a/Completion/Unix/Command/_subversion
+++ b/Completion/Unix/Command/_subversion
@@ -3,9 +3,8 @@
 _svn () {
   local curcontext="$curcontext" state line expl ret=1
   typeset -A opt_args
-  local i
 
-  # Colons and closing square brackets in values must be escaped.
+  # Colons in values must be escaped.
   local -A show_item_keys=(
      kind                  "the kind of TARGET (file or dir)"
      url                   "the URL of TARGET in the repository"
@@ -113,11 +112,7 @@ _svn () {
           done
           while (( idx=$args[(I)*--show-item:arg:] )); do
             # (q) to quote the parentheses in the value
-            local -a show_items_plain_array
-            for i in ${(k)show_item_keys}; do
-              show_items_plain_array+=( $i\[${show_item_keys[$i]}\] )
-            done
-            args[idx]=( --show-item'=:item key:_values -s , "info items" ${show_items_plain_array[@]}' )
+            args[idx]=( --show-item'=:item key:(('"`for i j in ${(kv)show_item_keys}; do print -rn - $i\\\\:"${(q)j}" ""; done`"'))' )
           done
           # All other options get {-x+,--long-x=}
           args=( ${args/(#b)(--[A-Za-z0-9-]##):arg:/$match[1]=:arg:} )