Hi
@ARGV = 'c:/temp/'; use File::Find (); $whole=''; sub find(&@) { &File::Find::find } *name = *File::Find::name; find { if ($name=~m#^(.*/)([^/]+$)#) { my $path=$1; my $file=$2; if ($whole=~m#<file>\Q$file\E</file>#si) { unlink("$name") or warn "couldn't unlink $name: $!"; print "\ndeleted $name"; } else { $whole.="\n".'<path>'.$path.'</path><file>'.$file.'</file> +'; } } } @ARGV;
Thanks,
Gopal.R
In reply to Re: Removing Duplicate Files
by gopalr
in thread Removing Duplicate Files
by tomazos
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |