RE: regex on the command line

2004-09-08 Thread Bob Showalter
Errin Larsen wrote: > Hi Perl-Buddies, > > I'm wondering how to get a regex into my code at run-time. I mean in > a command line like this: > > # my_perl_program "foo(\w|and|or)+bar" foobar.txt > > and in my code I want to be able to search the foobar.txt file with > the regex found in the quot

regex on the command line

2004-09-08 Thread Errin Larsen
Hi Perl-Buddies, I'm wondering how to get a regex into my code at run-time. I mean in a command line like this: # my_perl_program "foo(\w|and|or)+bar" foobar.txt and in my code I want to be able to search the foobar.txt file with the regex found in the quotes. So if I assign the above to a var