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

Re: fc -l -m 'some pattern'



Nick Croft wrote:

> I'm new at using zsh. Working through a tutorial.
> 
> I read that 
> 
>    Using the -m flag in conjunction with -l, you can specify a pattern.
>    (don't forget to quote the pattern!). Then, only commands matching
>    the pattern will be displayed. 
> 
> So for example, if 
> 
>    fc -l -300 -285 
> 
> shows that I used vim in a command a number of times, to isolate only the
> 'vim' occurrences should I not type
> 
>    fc -lm "vim" -300 -285    ?
> 
> Or do you need the entire command line? (That would be a severe
> limitation I think).

You need a *pattern* that matches the entire line. E.g.:

  fc -lm "vim*" -300 -285

Or even "*vim*".


Bye
  Sven

-- 
Sven Wischnowsky                          wischnow@xxxxxxxxx



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