------------------------------------------------
On Fri, 14 Feb 2003 10:13:06 -0500, Michael Pastore <[EMAIL PROTECTED]> 
wrote:

> 
> Hello All,
> 
> Is the only way to copy a file from one directory to another by using the
> copy module...?
> 
> Would anyone have a snipet of code copying a file from one dir to another...
> 
> Any assistance would be appreciated...
> 

Well you could shell out to the local copy program, but that would be less portable:

my $result = `cp $file $newfile`;

Or you could do the really tedious, open the file for reading, open the new file for 
writing, read the contents of the read file and print to the write file, close both 
files. But why would you want to do that?  Is there a particular reason for avoiding 
File::Copy?

http://danconia.org

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to