Re: File:: Copy

2006-12-20 Thread D. Bolliger
Jeff Pang am Mittwoch, 20. Dezember 2006 15:09: > "Dukelow, Don" <[EMAIL PROTECTED]> > >I can't get "use File::Copy" to work. I declare it at the beginning of > >script but when I try to use it latter nothing happens. There are no > > errors and nothing is copied. > > Did you also add "use strict

Re: File:: Copy

2006-12-20 Thread Dermot Paikkos
On 20 Dec 2006 at 8:00, Dukelow, Don wrote: > I can't get "use File::Copy" to work. I declare it at the beginning > of script but when I try to use it latter nothing happens. There are > no errors and nothing is copied. > > I'm using the command! > > copy($variable, $variable2); > > I've also

Re: File:: Copy

2006-12-20 Thread Jeff Pang
> >I can't get "use File::Copy" to work. I declare it at the beginning of >script but when I try to use it latter nothing happens. There are no errors >and nothing is copied. > Did you also add "use strict" and "use warnings" at the begin of the script and still saw nothing? -- Books below tr

RE: File Copy

2006-08-22 Thread Derek B. Smith
Apparently I can no longer send email to this list from my work account because of: The following message to was undeliverable. The reason for the problem: 5.1.0 - Unknown address error 550-'Mail from cardinal.com rejected because it does not accept bounces. This violates RFC 821/2505/2821 http://

Re: FILE::copy gives error undefined subroutine

2006-03-16 Thread Mr. Shawn H. Corey
JupiterHost.Net wrote: a) FILE::copy probably doesn;t exist but rather: File::Copy Sadly :( FILE::copy does exist in some operating systems; like MS DOS and Mac OX S. This is because they do not distinguish between uppercase and lowercase in file names. Perl seems to find the correct module

Re: FILE::copy gives error undefined subroutine

2006-03-16 Thread Sonika Sachdeva
Thanks for the pointers. On 3/16/06, JupiterHost.Net <[EMAIL PROTECTED]> wrote: > > Hello, > > > > > Please try to write cleaner code, its hard to read :) (See "Perl Best > Practices" by Damian Conway, Oreilley) > > > > > undefined subroutine &main::copy > > > > What could be the mistake? > > a)

Re: FILE::copy gives error undefined subroutine

2006-03-16 Thread JupiterHost.Net
Hello, Please try to write cleaner code, its hard to read :) (See "Perl Best Practices" by Damian Conway, Oreilley) undefined subroutine &main::copy What could be the mistake? a) FILE::copy probably doesn;t exist but rather: File::Copy b) you have not imported copy() into main:: so

Re: FILE::copy gives error undefined subroutine

2006-03-16 Thread Sonika Sachdeva
It works . Thank you all. On 3/16/06, Sonika Sachdeva <[EMAIL PROTECTED]> wrote: > > Thanks for your response. > > I did change the module name. It works but now it hangs at the copy > command without giving any warning/error. ( plz refer the code) > > > thanks, > > > On 3/16/06, Dermot Paikkos

Re: FILE::copy gives error undefined subroutine

2006-03-16 Thread Sonika Sachdeva
Thanks for your response. I did change the module name. It works but now it hangs at the copy command without giving any warning/error. ( plz refer the code) thanks, On 3/16/06, Dermot Paikkos <[EMAIL PROTECTED]> wrote: > > Is that File::Copy or FILE::copy? The former is what you want. > Dp. >

Re: FILE::copy gives error undefined subroutine

2006-03-16 Thread Mr. Shawn H. Corey
Sonika Sachdeva wrote: Hi All, I have used FILE::copy , perl syntax check is OK. and am getting the following error when it tries to perform the copy function . This is on windows system. That has to be: use File::Copy; Case is important in Perl. On certain OSes, like Mac OS X, case in file n

Re: FILE::copy gives error undefined subroutine

2006-03-16 Thread Dermot Paikkos
Is that File::Copy or FILE::copy? The former is what you want. Dp. On 16 Mar 2006 at 9:53, Sonika Sachdeva wrote: > Hi All, > > I have used FILE::copy , perl syntax check is OK. > and am getting the following error when it tries to perform the copy > function . This is on windows system. > >

Re: file::copy remote authentication

2005-01-11 Thread Jenda Krynicky
From: Paul Kraus <[EMAIL PROTECTED]> > I have a perl script that uses file::copy to copy files from a server > to the local machine. It does alot more then that but is pretty much > the jist of what is taking place. Currently i have to have the local > machine first establish the connection so that

Re: file::copy remote authentication

2005-01-11 Thread JupiterHost.Net
Paul Kraus wrote: I have a perl script that uses file::copy to copy files from a server Funny, I couls only find File::Copy on cpan but no file::copy :) to the local machine. It does alot more then that but is pretty much the jist of what is taking place. Currently i have to have the local machine

Re: File::Copy

2004-01-21 Thread Jeff 'japhy' Pinyan
On Jan 21, zentara said: >copy( "$ARGV[0]", "$ARGV[0]\.bak" ); >chmod ($mode, "$ARGV[0]\.bak"); >print "Backup completed.\n"; Why do you backslash the . in "$ARGV[0]\.bak" but not in "completed.\n"? Long story short, you don't need to \ the . in either case, and you don't need quotes around $ARG

RE: File::Copy

2004-01-20 Thread Tim Johnson
ECTED] Sent: Tuesday, January 20, 2004 4:46 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: File::Copy ->SNIP<-- So if you are on any of the three systems above andyou are NOT doing file handles, then the files should have the same file permissi

Re: File::Copy

2004-01-20 Thread Wiggins d'Anconia
Larry Guest wrote: Anyone know how to get File::Copy module to keep file permissions when it copies from one location to another? Thanks "File::Copy also provides the "syscopy" routine, which copies the file specified in the first parameter to the file specified in the second parameter, prese

RE: File::Copy

2004-01-20 Thread Wagner, David --- Senior Programmer Analyst --- WGO
This is what I found in ActiveState Doc concerning File::Copy: Special behaviour if syscopy is defined (OS/2, VMS and Win32) If both arguments to copy are not file handles, then copy will perform a ``system copy'' of the input file to a new output file, in order to preserve file attribut

Re: File::Copy & CGI.pm

2003-08-21 Thread Jenda Krynicky
From: "Yupapa.com" <[EMAIL PROTECTED]> > If you are transfering file from a local machine to a remote machine, > you do not use File::Copy module to copy files. File::Copy is used > for copying files locally. You can use Net::FTP to transfer files > from one machine to another. And of course, yo

Re: File::Copy & CGI.pm

2003-08-20 Thread Yupapa.com
HiHi~ If you are transfering file from a local machine to a remote machine, you do not use File::Copy module to copy files. File::Copy is used for copying files locally. You can use Net::FTP to transfer files from one machine to another. And of course, you will need a FTP server for the machine

Re: File::Copy & CGI.pm

2003-07-12 Thread Rob Dixon
B. Fongo wrote: > Hi, > > I've a small script intended for file transfer from a windows > machine to a remote linux server. To implement that, I decided to > use two module i.e File::Basename, File::Copy and CGI.pm. > > The File::Copy is working well locally, but it fails to copy files > to a remo

Re: File::Copy -> Additional Parameters? Thank you

2003-06-12 Thread Ben Crane
Okay, Some good leads to work with...Thanx for the heads up guys!! Ben __ Do you Yahoo!? Yahoo! Calendar - Free online calendar with sync to Outlook(TM). http://calendar.yahoo.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail:

Re: File::Copy -> Additional Parameters?

2003-06-12 Thread Beau E. Cox
- Original Message - From: "Ben Crane" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, June 11, 2003 11:21 PM Subject: RE: File::Copy -> Additional Parameters? > Yep, I've thought of that, but with so many files > (it's an

Re: File::Copy -> Additional Parameters?

2003-06-12 Thread Rob Dixon
Ben Crane wrote: > Yep, I've thought of that, but with so many files > (it's an internal backup) I don't want to slow the > process down by checking the source/dest filename on > both drives and their dates before copying, I was > hoping for there might be an obscure module out there > that handled

RE: File::Copy -> Additional Parameters?

2003-06-12 Thread Ben Crane
Yep, I've thought of that, but with so many files (it's an internal backup) I don't want to slow the process down by checking the source/dest filename on both drives and their dates before copying, I was hoping for there might be an obscure module out there that handled it neatly... If not, no wor

RE: File::Copy -> Additional Parameters?

2003-06-11 Thread Tim Johnson
You could always use stat() on the files to decide which ones you want to copy... -Original Message- From: Ben Crane [mailto:[EMAIL PROTECTED] Sent: Wednesday, June 11, 2003 4:31 AM To: [EMAIL PROTECTED] Subject: File::Copy -> Additional Parameters? Hi all, Anyone know if the perl modu

Re: File::Copy -> Additional Parameters?

2003-06-11 Thread Rob Dixon
Hi Ben Ben Crane wrote: > > Anyone know if the perl module File::Copy can handle > date checks? Or whether there is another module that > only deals with copying files that are newer than the > ones they are over-writing? > > Similar to the Xcopy /D: command > [I don't want to use a batch file at

Re: File::Copy question

2002-10-07 Thread John W. Krahn
Steve wrote: > > I am using Windows 98 and ActiveState Perl. I have a log file that after a > certain size is truncated and reused. I have written a simple script to > copy that file to another file using File::Copy. Is there a way to make > sure the second file is appended instead of overwrit

RE: File::Copy question

2002-10-07 Thread Timothy Johnson
Sorry for not explaining better. See commments below. -Original Message- From: Mat Harris [mailto:[EMAIL PROTECTED]] Sent: Monday, October 07, 2002 7:24 AM To: Timothy Johnson Cc: 'Steve'; [EMAIL PROTECTED] Subject: Re: File::Copy question if you want to append to a second

Re: File::Copy question

2002-10-07 Thread Mat Harris
if you want to append to a second file then you should use ">>" when opening, not ">" or you will delete the text already there. if it was just a typo then ignore me. On Mon, Oct 07, 2002 at 07:20:29 -0700, Timothy Johnson wrote: > > If you want to append the contents of one file to another, the

RE: File::Copy question

2002-10-07 Thread Timothy Johnson
If you want to append the contents of one file to another, then you will have to open both files, read the first one, and write it to the second one. Something like this should work: ## use strict; use warnings; open(LOG,"mylog.log") || die "Couldn't open logfile for readin

Re: File::Copy

2002-09-29 Thread Jeff 'japhy' Pinyan
On Sep 29, Steve said: >Is there a File::Copy available for ActiveState Win32? Yes; it is a standard module. -- Jeff "japhy" Pinyan [EMAIL PROTECTED] http://www.pobox.com/~japhy/ RPI Acacia brother #734 http://www.perlmonks.org/ http://www.cpan.org/ ** Look for "Regular Expressio

RE: FILE COPY

2002-09-23 Thread Timothy Johnson
TED]] Sent: Monday, September 23, 2002 11:45 AM To: [EMAIL PROTECTED] Subject: re: FILE COPY William Black wrote: > Does anyone know how to use the file copy module to past files to remote > servers? > > i.e. > > server 1:x > server 2:y > if your os is unix/linux. try if

Re: FILE COPY

2002-09-23 Thread Michael Fowler
On Mon, Sep 23, 2002 at 09:31:25AM -0400, William Black wrote: > Does anyone know how to use the file copy module to past files to remote > servers? File::Copy is for copying and moving files on the local filesystem. I'm not sure why you would be trying to apply it to this problem, or why you'd

re: FILE COPY

2002-09-23 Thread david
William Black wrote: > Does anyone know how to use the file copy module to past files to remote > servers? > > i.e. > > server 1:x > server 2:y > if your os is unix/linux. try if you have scp like: scp :from_file :to_file Windos might have something similar david -- To unsubscribe, e-mai

re: FILE COPY

2002-09-23 Thread William Black
Does anyone know how to use the file copy module to past files to remote servers? i.e. server 1:x server 2:y I want to copy the file named foobar from x to y. Can this be done? William Black _ MSN Photos is the easiest way

Re: File copy

2002-05-21 Thread Sudarsan Raghavan
Slavtek wrote: > Hello, > I want to copy some files from one place to another. Maybe someone tell me how can I >do this using Perl? > Thanks in advance! perldoc File::Copy Loop through the files in your source directory (using glob or opendir and readdir) and copy them. perldoc -f glob perldoc

Re: File::Copy limitation? on Win32

2002-01-08 Thread Jenda Krynicky
> I suspect the answer to this is "you can't abuse perl that way on > WinNT," but I'll post anyhow. > > I'm distributing files across several machines on an NT network; for > various reasons I need the status that the File::Copy module returns > but can't rely on mapped drives. > > UNCs and IP p

Re: file copy and create directory if necessary

2001-07-25 Thread Birgit Kellner
--On Mittwoch, 25. Juli 2001 12:45 -0800 Michael Fowler <[EMAIL PROTECTED]> wrote: > can't be done; the regex memory variables ($1, $2, $3, etc.) are > read-only. I had already noticed that when I tried it in the meantime :-) > It's really irrelevant, though; the trailing slash can be left in,

Re: file copy and create directory if necessary

2001-07-25 Thread Michael Fowler
On Wed, Jul 25, 2001 at 08:46:21PM +0200, Birgit Kellner wrote: > --On Mittwoch, 25. Juli 2001 09:27 -0800 Michael Fowler > <[EMAIL PROTECTED]> wrote: > > Assume $targetdir holds "/home/somedir" and $2 holds > "/anotherdir/yetanotherdir/"; > So, to check if the dir /home/somedir/anotherdir/yetan

Re: file copy and create directory if necessary

2001-07-25 Thread Birgit Kellner
--On Mittwoch, 25. Juli 2001 09:27 -0800 Michael Fowler <[EMAIL PROTECTED]> wrote: Thanks for the hint to File::Path; Just one more question to make sure: >> foreach $file (@files) { >> >> ### $destfile will be the copied file in subdir admin, $file the >> ### original >> file in $origd

RE: file copy and create directory if necessary

2001-07-25 Thread Ross, Jonathan C.
> I am using File::Find and File::Copy to accomplish the following: > check a directory tree for all files that end in *.html and copy them to a > different directory, preserving the tree structure. > The following code works fine provided that all subdirectories already > exist. But is there a

Re: file copy and create directory if necessary

2001-07-25 Thread Michael Fowler
On Wed, Jul 25, 2001 at 04:22:01PM +0200, Birgit Kellner wrote: > Hi, > > I am using File::Find and File::Copy to accomplish the following: > check a directory tree for all files that end in *.html and copy them to a > different directory, preserving the tree structure. > The following code work