The one-liner approach:
$ cat input.txt one two three four five six seven $ perl -ne 'print $_ = <> and last if /five/' input.txt six
In reply to Re: Getting next line after matched one
by rnahi
in thread Getting next line after matched one
by ramthen
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |