[Israel.pm] how to find lines range (regex)

Yossi Itzkovich Yossi.Itzkovich at ecitele.com
Tue Mar 25 12:06:58 EET 2008


Hi,

What's the best/simple way to find all lines between startPattern and
StopPattern:

@text= ( "ahfdj\n",
		"ksjdf\n",
		"startPattern\n",
		"gjdhgf\n",
		"kljsd\n",
		"stopPattern\n",
		"jsadflj\n");

I would like to get a list of those 2 items in the middle

Thanks

Yossi


More information about the Perl mailing list