in reply to copying directories and sub directories

You could also try File::Copy::Recursive.
  • Comment on Re: copying directories and sub directories