For Programmers: Free Programming Magazines  


Home > Archive > PERL Beginners > January 2006 > copying directories?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author copying directories?
rohan

2006-01-20, 6:59 pm

hey..
I am wondering how do I copy an entire directory to another location?
I didnt see any references of it in the "copy" command man page.. I
could read the location.. and recurse through each dir to and copy
files.. or i can run a qx/cp D1 D2 -rf/... but there has to be a
better way...?
Thanks..


...R

Paul Lalli

2006-01-20, 6:59 pm

rohan wrote:
> I am wondering how do I copy an entire directory to another location?


http://search.cpan.org/~dmuey/File-...16/Recursive.pm

Paul Lalli

rohan

2006-01-20, 6:59 pm

:) ty!!

...R

usenet@DavidFilmer.com

2006-01-20, 6:59 pm

Paul Lalli wrote:
> http://search.cpan.org/~dmuey/File-...16/Recursive.pm


That's probably what the OP is looking for. But, FWIW, I use
File::Rsync for this type of thing (which doesn't really care if I'm
doing a recursive copy on the same machine or two different machines;
that flexability can come in handy).

--
http://DavidFilmer.com

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2009 codecomments.com