#!/usr/bin/perl -w use strict; my $dir = "C:\\TEMP\\"; my $outdir = "C:\\temp2\\"; opendir (DIR, $dir) || die "can't open $dir: $!"; my @files = readdir(DIR); close(DIR); foreach (@files) { # change the extension to one of your liking if ($_ =~ /.log/) { system ("copy $dir\\$_ > $outdir\\$_"); } }
In reply to Re: Re: Re: Re: read copy and moving files
by softworkz
in thread read copy and moving files
by cal
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |