Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Tip of the day: previous command output



On 2004-08-20 21:25:47 -0700, Bart Schaefer wrote:
> > And how about typing a pattern somewhere in the command line, then
> > applying a function that replaces this pattern by the matching lines
> > (quoted) of $kept?
> 
> You'll have to be more specific.  You mean something like expand-word,
> except that the expansion gets stashed in $kept first?

No, I mean that instead of expanding to filenames, one expands
to lines from $kept (but only those that match the pattern).
For instance, if $kept is (ab ac bc) and [ESC][TAB] is bound
to the function in question, then

  a*[ESC][TAB]

gives

  ab ac

-- 
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <http://www.vinc17.org/>
100% validated (X)HTML - Acorn / RISC OS / ARM, free software, YP17,
Championnat International des Jeux Mathématiques et Logiques, etc.
Work: CR INRIA - computer arithmetic / SPACES project at LORIA



Messages sorted by: Reverse Date, Date, Thread, Author