Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic

Re: Replication of directory subtrees

by eduardo (Curate)
on Apr 24, 2003 at 14:52 UTC ( #252913=note: print w/ replies, xml ) Need Help??

in reply to Replication of directory subtrees

I hate to offer a non-perlish solution, but have you ever considered using xcopy? It would seem like you are on a win32ish system... and xcopy is exactly what this was designed for.

All that being said, if you need this to be cross platform, you are *way* better off with some of the other monks answers :)

Comment on Re: Replication of directory subtrees
Re: Re: Replication of directory subtrees
by rbi (Monk) on Apr 24, 2003 at 15:05 UTC
    Yes, It is going to be subroutine within a CGI application that should run both under MsWin32 and Unix.
      well, in that case!
      if ($^O =~ /win32/i) { # do stuff with xcopy } else { # do stuff with cp -r }
      I am *not* advocating this solution... I just thought it would be cheesy way to do it. Please, for the love of anything you may or may not hold holy, use something like File::Find or File::NCopy instead like merlyn suggested.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://252913]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (6)
As of 2015-03-29 08:14 GMT
Find Nodes?
    Voting Booth?

    When putting a smiley right before a closing parenthesis, do you:

    Results (630 votes), past polls