On Thursday 23 Dec 2004 2:55 pm, Vinu Balaji wrote:
> > [EMAIL PROTECTED]:~$  ps aux|grep grep|head --lines=-1
> > shridhar 31926  0.0  0.1  1676  584 pts/55   S+   12:44   0:00 grep -
>
> You can this to achieve the same!
> #bash# ps aux | grep -m 1 grep

not good enough. If you have more than one  long running grep, it will still 
show just one.

With head you eliminate the last grep, which is your grep(most probably) 
because they are ordered by pid..:-)

 Shridhar


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
_______________________________________________
linux-india-help mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-india-help

Reply via email to