perlisfun has asked for the wisdom of the Perl Monks concerning the following question:
I used to use linux a lot. I liked its grep command which has -A and -B option. -A <line_numbers> gives number of lines after the matching, -B <line_numbers> gives number of lines before the matching.
Right now, i am working on Solaris. Its grep does not have these features. I can write a program to achieve the goal. Actually i really don't want to reinvent the weel. Can some one shed some light on this with perl module or some other perl shortcut? Thanks,
PerlIsFunUpdated 2003-06-11 by mirod: changed title and added formating.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: linux grep feature
by hardburn (Abbot) on Jun 11, 2003 at 14:28 UTC | |
by gellyfish (Monsignor) on Jun 11, 2003 at 14:49 UTC | |
|
(jeffa) Re: linux grep feature
by jeffa (Bishop) on Jun 11, 2003 at 14:54 UTC | |
by cees (Curate) on Jun 11, 2003 at 15:47 UTC | |
|
Re: linux grep feature
by fglock (Vicar) on Jun 11, 2003 at 17:51 UTC | |
|
Re: linux grep feature
by cees (Curate) on Jun 11, 2003 at 16:56 UTC | |
|
Re: linux grep feature
by Thelonius (Priest) on Jun 11, 2003 at 17:14 UTC |