
"lcd" Within an FTP Script
On 2000-01-06 colin_te...@my-deja.com said:
>I'm having a problem changing my local directory
>within my Korn shell FTP script. The FTP script
>worked well until I tried adding an "lcd"
>command. My current script looks like this...
>HOST=<ip address>
>DESTDIR='e:\\ftp\\ftpdest'
>SRCDIR=<source directory>
>ftp -n -v -i $HOST <<!
>user <userid> <userpass>
>lcd $DESTDIR
>cd $SRCDIR
>bin
>hash
>prompt
>mget *
>close
>quit
>!
>I get an error message saying that the directory
>can't be found. The directory exists and can be
>accessed via a normal FTP session. Any help with
>this problem would be greatly appreciated.
Are you sure you need to double the backslashes inside single quotes? Or,
assuming that you are using a Unix shell over some version of DOS or Windows,
you might be able to use forward slashes instead of back slashes for the
local directory.
Net-Tamer V 1.08X - Test Drive