Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

mystixman

macrumors regular
Original poster
Aug 11, 2002
114
0
USA
I want to upload a file in one line in the terminal ( for an applescript )

I already know how to include the user and pass in it, but don't know how to include the file and where i want to put it. I checked the man page and didn't see it or didn't SEE it. Any help would be greatly appreciated.
 
You should be able to put the user account and password in a text file and pass it to ftp.

Create a text file--I would name it for the server--with contents like this

myuseraccount
myuserpassword

I would also create a script named for the transfer, with contents like this:

#!/bin/sh
ftp ftp.someserver.com <someserver.txt

It should pass the information as ftp asks for it.
 
If that doesn't work, post again. I have some scripts for ftping particular files to particular hosts and I could turn one into something generic to post for you.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.