From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-users@sunsite.dk
Subject: Re: zshzle: aborting history search
Date: Sat, 17 Jul 2004 19:31:05 -0700 (PDT) [thread overview]
Message-ID: <Pine.LNX.4.60.0407171917400.10364@toltec.zanshin.com> (raw)
In-Reply-To: <dbe.40f97840.4f0d2@georgn.fqdn.th-h.de>
On Sat, 17 Jul 2004, Georg Neis wrote:
> "bck-i-search: cat /fo" turns into "failing bck-i-search: cat /fo"
> because the command is (for whatever reasons) not in my history file.
> Now I want to [move] "cat /fo" from the search prompt to the normal
> command prompt
copy-search-as-buffer() { zle end-of-history; BUFFER="$LASTSEARCH" }
zle -N copy-search-as-buffer
bindkey '\ee' copy-search-as-buffer
Choose your own binding in place of escape-e, I just picked something that
isn't bound by default. The "end-of-history" isn't strictly necessary,
but it means you aren't left with a modified buffer in the middle of the
history after the first part of the incremental scan.
next prev parent reply other threads:[~2004-07-18 2:33 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-17 16:49 Georg Neis
2004-07-17 18:47 ` Wayne Davison
2004-07-17 18:56 ` Bart Schaefer
2004-07-17 19:04 ` Georg Neis
2004-07-17 19:43 ` Felix Rosencrantz
2004-07-26 9:36 ` Peter Stephenson
2004-07-28 14:52 ` Felix Rosencrantz
2004-07-18 2:31 ` Bart Schaefer [this message]
2004-07-18 9:21 ` Georg Neis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.60.0407171917400.10364@toltec.zanshin.com \
--to=schaefer@brasslantern.com \
--cc=zsh-users@sunsite.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).