Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/perl
- use File::Copy;
- $in_dir=$ARGV[0];
- $dest_dir=$ARGV[1];
- chdir($in_dir);
- @dir_files=<*>;
- foreach $dir (@dir_files)
- {
- if($dir=~/pdf/)
- {
- move("$dir","$dest_dir") or die "Move failed, $!";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement