[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] Copying/moving files



At 14.41 11/4/97, Paul Williams wrote:
>Is there any senseible way to move or copy files within MacPerl or is it
>best done with an AppleScript?

To move a file, use the Perl rename() function.  To copy, you can use the File::Copy module.

        use File::Copy;
        copy($origfile,$newfile);

Same as on any other version of Perl.  There are some MacPerl-specific copying functions in the Mac::MoreFiles module, but they are not necessary.  Actually, File::Copy uses Mac::MoreFiles when run by MacPerl.

--
Chris Nandor               pudge@pobox.com           http://pudge.net/
%PGPKey=('B76E72AD',[1024,'0824 090B CE73 CA10  1FF7 7F13 8180 B6B6'])
#==                    MacPerl: Power and Ease                     ==#
#==    Publishing Date: Early 1998. http://www.ptf.com/macperl/    ==#



***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch