From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24819 invoked by alias); 15 Feb 2014 23:29:59 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 32393 Received: (qmail 20114 invoked from network); 15 Feb 2014 23:29:53 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 X-Originating-IP: [86.6.157.246] X-Spam: 0 X-Authority: v=2.1 cv=L4GTQoj8 c=1 sm=1 tr=0 a=BvYiZ/UW0Fmn8Wufq9dPrg==:117 a=BvYiZ/UW0Fmn8Wufq9dPrg==:17 a=NLZqzBF-AAAA:8 a=M48_sP4uWhMA:10 a=uObrxnre4hsA:10 a=P8Bb1jSOJukA:10 a=VPRr9u8j4ax5HqxtrA8A:9 a=_dQi-Dcv4p4A:10 Message-Id: <201402152329.s1FNTnO9027345@pws-pc.ntlworld.com> X-Authentication-Warning: pws-pc.ntlworld.com: pws owned process doing -bs From: Peter Stephenson To: zsh-workers@zsh.org Subject: Re: SUGGESTION: Simplify auto-completion, a little In-Reply-To: Message from Bart Schaefer of "Sat, 15 Feb 2014 15:15:26 PST." <140215151526.ZM2197@torch.brasslantern.com> Date: Sat, 15 Feb 2014 23:29:49 +0000 Bart Schaefer wrote: > On Feb 15, 9:45pm, mail@bwe.im wrote: > } > } Now: git com > } Future: git com > } Result: git commit > } > } It would be sufficient just hitting the symbol `m' to auto-complete to > } `git commit`. > > Ordinary keybindings don't work that way; the "m" key is bound to the > self-insert widget and does not re-enter completion. You should seek > out one of the various options for enabling "predictive typing", or > you should try setting up menu-selection (so that the first tab would > take you into a different keymap where "m" would select from among > the possible choices). Hmm... I'm not sure how easy it is to do that at the moment. There is a keymap for menu-selection, but I think it's only got a limited set of functions to do with the menu --- I don't think you can make a key execute a widget that leaves completion with the command line as it is *and* does normal (non-completion) ZLE stuff like self-insert and re-enter completion, can you? This implies a level of tweaking stuff within the completion function environment it's not currently desiged to do. It probably wouldn't be beyond the wit of humankind to add an internal widget like narrow-completion that could retrieve the list of completions and narrow it down, but I bet it's still not trivial. -- Peter Stephenson Web page now at http://homepage.ntlworld.com/p.w.stephenson/