Jim,
Use perl: (I'm sure someone will improve on this script. It's just a
quick hack.)
#!/usr/bin/perl -w
use Net::FTP;
$ftp=Net::FTP->new('ftp-server',Timeout => 30,Debug => 0) or die("Failed
to connect. : $! $? $@\n");
$ftp->login('user-name',,'password') or die("Failed to login. : $!
$?\n");
$ftp->hash() or die("Failed to set hash mode. : $! $?\n");
$ftp->put('my-source-file','target-file') or die("Failed to put file. :
$! $?\n");
$ftp->close() or warn("Failed to close. Oh, well... : $! $?\n");
exit;
Best regards
Gustav
Jim Baxter wrote:
>
> Hi
>
> We do not seem to be able to run ftp from a shell script or script ftp.
> The man page talks about macros but they go away at close.
> What we need is the ability to start ftp, login and get (or put) a list of
> files and
> log off all from a shell script
>
> Can some one tell me how to do it or where to get RPM of another version of
> ftp that
> will do it?
>
> Thanks
>
> Jim Baxter
> MIS
> Morrison Supply Company
>
> --
> To unsubscribe: mail [EMAIL PROTECTED] with "unsubscribe"
> as the Subject.
--
pgp = Pretty Good Privacy.
To get my public pgp key, send an e-mail to: [EMAIL PROTECTED]
Visit my web site at http://www.schaffter.com
--
To unsubscribe: mail [EMAIL PROTECTED] with "unsubscribe"
as the Subject.