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

[cobalt-users] Re: OT: FTP from Command line



------------------------
d=$(date +%Y-%m-%d)

ftp -i ftp.server.tld <<**
cd /mydirname
mkdir $d
chmod 600 $d
cd $d
binary
mput *
ls -x1A
bye
**
------------------------

I need it to also chmod the files that it transfers to 600 but I can't seem to get that to work.

Can you just change the order of the commands?

------------------------
d=$(date +%Y-%m-%d)

ftp -i ftp.server.tld <<**
cd /mydirname
mkdir $d
cd $d
binary
mput *
chmod 600 *
ls -x1A
bye
**
------------------------