Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
[PATCH] _svn: Complete propvals in 'propset'.
- X-seq: zsh-workers 41471
- From: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: [PATCH] _svn: Complete propvals in 'propset'.
- Date: Thu, 27 Jul 2017 13:38:54 +0000
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= daniel.shahaf.name; h=date:from:message-id:subject:to :x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s=fm1; bh=J3Hw6a 1zatdAQr+XAwY9R7tIjWrs2XMCExvHVN6c7Qk=; b=e7hF6YHbO3uXhYZIR5rwrf fo1BgOxwl41gHAVWGiod1OtlIkQMCfqXrSKZoTq3Gg1ArOeUYTDsmJISbyelM6nk WLpvbOTGUrdoJN/CJ5U20dPZwJvXlCo7vwQgIewIz3Dci9bnTWbtuLo1cCRqrvd8 26QoQ4bmhjVv7bUSyxQ61xFR2XBHTipXA+Gd7VbfOOs2E56nK3nowPe2yQXwCnJt tbhQ+tU6zLBIRxAm4jePRYGkyKs63K4s17MPZjAj9tUmEHz2AN4t++VrEZECUALh 9vp5hDdulPb5VMEAefGqx5nlNKxV4IqnRfmwHD4VqQjSFPwjppUN/G9PBtLQUJ1A ==
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=date:from:message-id:subject:to :x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s=fm1; bh=J3Hw6a 1zatdAQr+XAwY9R7tIjWrs2XMCExvHVN6c7Qk=; b=rr1HXoknoP7v7meApYVU/K ZgLZQJ5OCWPaSPy4qqPEHC4gbO9V5K0tAuye6UcJ+E3rB1XhDQGhmw3y1ZT8u237 sQwLYVcf8n2lqwUePmR3vM77/FRxR5tdOqUZ8I9k1CEd+FUO9rIYibEzPJYdmxmV 1BaT9ILpEOVFguRCOqUKnceRJKKnL+B3QaFjbqsFX/oPONJs7Dd8yd+MNJ8PmxMf OxUIUMl1K14PKceoIPPVACop9Glqm/5zdX0aOApMSRQQOfLgIBVSmKp/xlYBXhmd YbwXxWHFG+QyZ8pLBBlNkhDhb9nyzkK60uuZV0gh35VpHxiooufhEtreVk8J6KXw ==
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
---
Completion/Unix/Command/_subversion | 25 ++++++++++++++++++++++++-
1 file changed, 24 insertions(+), 1 deletion(-)
diff --git a/Completion/Unix/Command/_subversion b/Completion/Unix/Command/_subversion
index 2f6b567ac..b4e6c2e6e 100644
--- a/Completion/Unix/Command/_subversion
+++ b/Completion/Unix/Command/_subversion
@@ -150,7 +150,8 @@ _svn () {
;;
(propset)
args=(
- ':propname:(svn:ignore svn:keywords svn:executable svn:eol-style svn:mime-type svn:externals svn:needs-lock)'
+ ':propname:(svn:ignore svn:keywords svn:executable svn:eol-style svn:mime-type svn:externals svn:needs-lock svn:global-ignores svn:auto-props)'
+ ':propval:->propset_propval'
${args/(#b)(*--file*):arg:/$match[1]:file:_files}
'*:path or url: _alternative "files:file:_files" "urls:URL:_svn_urls"'
)
@@ -179,6 +180,28 @@ _svn () {
esac
_arguments "$args[@]" && ret=0
+ case $state in
+ (propset_propval)
+ case $words[2] in
+ (svn:executable|svn:needs-lock) compadd yes;;
+ (svn:keywords)
+ compset -q
+ # '_values -w' only excludes words in argv[1] or later, so
+ # install a dummy argv[0]. This affects Foo in [[svn propset
+ # svn:keywords 'Foo Bar Baz <TAB>]].
+ words=( dummy $words ); (( ++CURRENT ))
+ _values -s ' ' -w "keywords (or custom)" \
+ '(URL HeadURL)'{URL,HeadURL}'[The URL for the head version of the file]' \
+ '(Author LastChangedBy)'{Author,LastChangedBy}'[The last person to modify the file]' \
+ '(Date LastChangedDate)'{Date,LastChangedDate}'[The date/time the file was last modified]' \
+ '(Rev Revision LastChangedRevision)'{Rev,Revision,LastChangedRevision}'[The last revision the file changed]' \
+ Id'[A compressed summary of URL,Revision,Date,Author]' \
+ Header'[Similar to Id but includes the full URL]';;
+ (svn:eol-style) compadd - CR LF CRLF native;;
+ (svn:mime-type) _mime_types;;
+ (*) _message 'property value';;
+ esac
+ esac
else
_message "unknown svn command: $words[1]"
Messages sorted by:
Reverse Date,
Date,
Thread,
Author