[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

[Q] Looking for the Ruby equivalent of this Unix command...

Lyle Johnson

11/18/2003 5:31:00 PM

Is this:

File.syscopy(fromName, toName)

the equivalent of this:

$ cp -p fromName toName

?

1 Answer

gabriele renzi

11/18/2003 9:08:00 PM

0

il Tue, 18 Nov 2003 11:31:16 -0600, Lyle Johnson
<lyle@users.sourceforge.net> ha scritto::

>Is this:
>
> File.syscopy(fromName, toName)
>
>the equivalent of this:
>
> $ cp -p fromName toName
>
>?

I think
require 'fileutils'

FileUtils.cp from , to, :preserve=>true