Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
[PATCH] Completion: Always offer -F/-m for `git tag`
- X-seq: zsh-workers 43974
- From: dana <dana@xxxxxxx>
- To: Zsh workers <zsh-workers@xxxxxxx>
- Subject: [PATCH] Completion: Always offer -F/-m for `git tag`
- Date: Fri, 4 Jan 2019 14:55:16 -0600
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dana-is.20150623.gappssmtp.com; s=20150623; h=from:content-transfer-encoding:mime-version:subject:message-id:date :to; bh=qRhFJZ1RWudLjluaildR1dKsuErtf3SET49wpTHa14o=; b=bWzSVSGoF3DbiguXFh8uh+VfR3lisOUQjFr8z/FeHYz/75aUqfH3dkL34j5J0zqiqe F+UadXgfhoZmXQADt1MtTqy86zfKAMcbHHwhDE8xFm3d/gujLgyhNUv/OMOYyBVXhnvv gOUarEUxNZiWqM4sxy4X+CmwDH5KPzxVWf2Anp1UBseV9Mr4AW6NxQIRx6ne1ZrvdItU wuhaGaNnK5qYtUPMDEArgFGETVIxDFj95n6Ix3MgnmmLptxF7Nkc08r5W1Bb65b7G3PR zPkhEI7S2Fv0yP9cxvEZKV57iiluyXoUZZVKO9AQ/SE6ZtePnwDy5XXbvjHgoR5NblMw DJow==
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
Another thing i noticed whilst following the release instructions, thought i
might as well fix it before going on:
_git-tag doesn't offer -F/-m unless -a/-s/-u are already provided, but this
isn't necessary or helpful; the man page for `git tag` says that -F/-m without
-a/-s/-u implies -a.
dana
diff --git a/Completion/Unix/Command/_git b/Completion/Unix/Command/_git
index 093464625..0ebbbe861 100644
--- a/Completion/Unix/Command/_git
+++ b/Completion/Unix/Command/_git
@@ -2017,15 +2017,6 @@ _git-subtree () {
(( $+functions[_git-tag] )) ||
_git-tag () {
- local -a message_opts
-
- if (( words[(I)-[asu]] )); then
- message_opts=(
- '(-m --message -F --file)'{-m+,--message=}'[specify tag message]:message'
- '(-m --message -F --file)'{-F+,--file=}'[read tag message from given file]:message file:_files'
- )
- fi
-
_arguments \
- creation \
'(-a --annotate -s --sign -u --local-user)'{-a,--annotate}'[create an unsigned, annotated tag]' \
@@ -2035,7 +2026,8 @@ _git-tag () {
'(-f --force)'{-f,--force}'[replace existing tag]' \
'--create-reflog[create a reflog]' \
'--cleanup=[cleanup message]:mode:((verbatim\:"no cleanup" whitespace\:"remove leading and trailing whitespace" strip\:"remove leading and trailing whitespace and comments"))' \
- $message_opts \
+ '(-m --message -F --file)'{-F+,--file=}'[read tag message from given file]:message file:_files' \
+ '(-m --message -F --file)'{-m+,--message=}'[specify tag message]:message' \
': :__git_tags' \
':: :__git_commits' \
- deletion \
Messages sorted by:
Reverse Date,
Date,
Thread,
Author