On Thu, 8 Nov 2001, Rajeev Nalluri wrote: > Is there any grep commandto search inside a file? perldoc grep gives a grep > command on a string, not files. > > And also I cannot use either backticks or system to use unix grep command. > I want to know is there any perl function to handle grep in a file.
What's wrong with using Perl's regular expressions to pull a pattern out of a file? while(<FILE>) { print if /pattern/; } -- Brett http://www.chapelperilous.net/ ------------------------------------------------------------------------ A mushroom cloud has no silver lining. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]