Grep a block of code

Hi

Lately someone gave me a task, to grep from csv file but a block of
code.
How to do it ?

for example

2 3 4 5

How to use grep to give me all form file wich start with and end
with

I’ve tried that way…

puts File.readlines(ARGV[0]).grep(/ * </tag>/)

Please help

From: “Maciej Pindela” [email protected]

I’ve tried that way…

puts File.readlines(ARGV[0]).grep(/ * </tag>/)

puts ARGF.read.scan(/.*?</tag>/m)

Regards,

Bill

Bill K. wrote:

From: “Maciej Pindela” [email protected]

I’ve tried that way…

puts File.readlines(ARGV[0]).grep(/ * </tag>/)

puts ARGF.read.scan(/.*?</tag>/m)

Regards,

Bill

Thanks that’s works