Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
[PATCH 2/4] _git-config: Fix a bug where a second trailing dot would be incorrectly offered.
- X-seq: zsh-workers 46129
- From: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: [PATCH 2/4] _git-config: Fix a bug where a second trailing dot would be incorrectly offered.
- Date: Fri, 26 Jun 2020 18:06:40 +0000
- In-reply-to: <20200626180642.11809-1-danielsh@tarpaulin.shahaf.local2>
- 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
- References: <20200626180642.11809-1-danielsh@tarpaulin.shahaf.local2>
- Sender: zsh-workers@xxxxxxx
---
Completion/Unix/Command/_git | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/Completion/Unix/Command/_git b/Completion/Unix/Command/_git
index 87551a17d..e860a5063 100644
--- a/Completion/Unix/Command/_git
+++ b/Completion/Unix/Command/_git
@@ -3025,11 +3025,7 @@ __git_config_option-or-value () {
local opt
declare -a match mbegin mend
for opt in ${${${${(M)git_options:#(#i)${IPREFIX}[^.:]##:*}#(#i)${IPREFIX}}/#(#b)([^:]##:)([^\\:]#(\\?[^\\:]#)#:[^\\:]#(\\?[^\\:]#)#:->bool)/$match[1]whether or not to $match[2]}/#(#b)([^:]##:([^\\:]#(\\?[^\\:]#)#))*/$match[1]}; do
- # TODO: Completing the option names 'core.splitIndex' or 'grep.column'
- # offers a second, trailing dot, because there are also options
- # called 'splitIndex.foo' and 'column.bar' (some of them are
- # added to $git_options as "unknown option name").
- if (( ${git_options[(I)${opt%%:*}.*]} )); then
+ if (( ${git_options[(I)${IPREFIX}${opt%%:*}.*]} )); then
sections_and_options+=$opt
else
options+=$opt
Messages sorted by:
Reverse Date,
Date,
Thread,
Author