Rob E McCormick wrote:
> 
> > How are the new file names defined?  Are they based on the old file
> > names or something else?
> >
> > open IN, $old_filename
> >     or die "cannot open $old_filename for reading: $!";
> > open OUT,">$newdir/$with_new_filename"
> >     or die "cannot create $newdir/$with_new_filename: $!";
> 
> Thanks for your suggestions....I would like to take each old filename
> ('ex020525.log' or exyymmdd.log...) and output
> 
> 'exyymmdd.new'  or even 'exyymmdd.log.new'


To apply this to your original program you could do something like this:


#!/usr/bin/perl -w
use strict;

my $newdir = '/something';
$^I = "$newdir/*.new";

while ( <> ) {
    if (
m!^#|CommunityID=399|/developersupport/testfiles|/remotegadgets/marks/gadget!
) {
        print;
        }
    }

__END__



John
-- 
use Perl;
program
fulfillment

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to