in reply to Copying all files and subdirectories from one directory to another..
Do you know how/why cpnewest works? Do you know why it's a bad idea?sub cpnewest { copy("$sourcedir$_","$destination$_"); }
And last but not least, where on earth do you opendir DIR?
You could also use a little more whitespace (indent yer code -- perltidy).
What's the purpose of having @files, @dirlist? Does it really matter that you process/check @files first?
I hope this is enough food for thought (if you're wondering what kind of food, angel-food ).
|
|---|