On 5/6/05, macromedia wrote:
>
> Hello,
>
> I'm not sure about the login or how I should approach what I want to
> achieve. I require a script that does the following.
>
> 1. Search a directory and all sub-directories for a certain file
> extension. (Ex. .txt)
>
> 2. Get the results of the abov
Hello,
A bash script would be a better choice for this particular request.
#!/bin/bash
find . -type f -name "*.txt" -print | xargs grep -l 123 >> externalfile
The above command would search the current directory plus all sub-
directories for all files the end in a ".txt" and search each
mpilation errors.
-Original Message-----
From: Gavin Henry [mailto:[EMAIL PROTECTED]
Sent: Friday, May 06, 2005 12:24 PM
To: beginners@perl.org
Subject: Re: Writing my first perl script
On Friday 06 May 2005 16:50, macromedia wrote:
> Something like this?
>
> #!/usr/bin/perl -w
>
essage-
> From: Gavin Henry [mailto:[EMAIL PROTECTED]
> Sent: Friday, May 06, 2005 11:24 AM
> To: beginners@perl.org
> Subject: Re: Writing my first perl script
>
>
>
> > Hello,
> >
> > I'm not sure about the login or how I should approach what I want to
>
ile () {
if ($line =~ /$num/ {
print $line;
}
}
close FILE;
}
-Original Message-
From: Gavin Henry [mailto:[EMAIL PROTECTED]
Sent: Friday, May 06, 2005 11:24 AM
To: beginners@perl.org
Subject: Re: Writing my first perl script
>
> Hello,
>
> I'm n
>
> Hello,
>
> I'm not sure about the login or how I should approach what I want to
> achieve. I require a script that does the following.
Here are the quick answer, which provide you some reading material:
>
> 1. Search a directory and all sub-directories for a certain file
> extension. (Ex. .t