Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH: glob flags at start of word
- X-seq: zsh-workers 43860
- From: Peter Stephenson <p.stephenson@xxxxxxxxxxx>
- To: Zsh Hackers' List <zsh-workers@xxxxxxx>
- Subject: PATCH: glob flags at start of word
- Date: Tue, 4 Dec 2018 16:53:09 +0000
- Cms-type: 201P
- Dkim-filter: OpenDKIM Filter v2.11.0 mailout1.w1.samsung.com 20181204165311euoutp01de5b3cb53697620cfce2177e0d9d8b89~tL2zbxoT30146401464euoutp01N
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1543942391; bh=r1GkZlVZD0BR/U7og+r4UncLj8Q8u7Yz8DxFCtS6ptY=; h=Subject:From:To:Date:References:From; b=UJ8y1kGhNdpSanBW+vEXcGxG5bQblRQZIlLyrqoemwaxEE3evFLbsDRRNdFxPXoNR JLCSaGBHuKRbkaqGIMtRDwpLIKorr5RYk2F6VnJR3/04bCj/SGcTWXHqUa3RcveKI5 OnZnpF0iMS1fUOyeGpWOKZgx82eb/jlE6GHvFzBM=
- 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: <CGME20181204165310eucas1p15a1a87a45a4de6508fa8457a64e5d9cf@eucas1p1.samsung.com>
ls (#<TAB>
doesn't complete as globbing flags are treated as a special case of glob
qualifiers, which can't be completed here.
Fairly minor but I can't see any good reason not to fix it.
pws
diff --git a/Completion/Unix/Type/_files b/Completion/Unix/Type/_files
index 2b0c558..d44ac31 100644
--- a/Completion/Unix/Type/_files
+++ b/Completion/Unix/Type/_files
@@ -17,6 +17,10 @@ if _have_glob_qual $PREFIX; then
_globquals && ret=0
fi
return ret
+elif [[ $_comp_caller_options[extendedglob] == on ]] && compset -P '\(\#'; then
+ # Globbing flags can start at beginning of word, even though
+ # glob qualifiers can't.
+ _globflags && return
fi
local opts tmp glob pat pats expl tag i def descr end ign tried
Messages sorted by:
Reverse Date,
Date,
Thread,
Author