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

Re: trouble with multiple pipes



On Wed, Jun 16, 1999 at 01:18:18PM -0700, dado wrote:
> Dominik Vogt wrote:
> 
> > (snip)
> 
> have you tried egrep ?

Yes, it works, but that doesn't really help since there are more
commands (other than grep) in the pipe I use. Anyway, I
solved the problem by writing a zsh script that does the filtering
with builtin commands :) (zsh is really *great*)

> # tail -f foo | egrep -v "5|4"
> 
> > And now I want to remove '4' from the output too:
> >
> >   # tail -f foo | grep -v 5 | grep -v 4
> >   (no output generated, pressed ^C)
> >
> > But when I terminate 'tail'
> >   # killall tail
> >   1
> >   2
> >   3
> >   zsh: terminated  tail -f foo |
> >   zsh: done        grep -v 5 | grep -v 4
> >
> > Why doesn't get the output of the first pipe get through to
> > the second one? Any ideas how to circumvent this problem?
> > Unfortunately I need to filter the output from a running
> > daemon in this way, but I'm out of ideas.
> >
> > The same behaviour occurs on HP-UX 10.20 (not that I think the
> > OS matters) or with ksh or bash.

Bye

Dominik ^_^

--
Dominik Vogt, dominik.vogt@xxxxxx
Reply-To: dominik.vogt@xxxxxx



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