I would like to sync a local folder on my Mac to a remote ftp server. I only want to upload files changed since last sync. I would also like to download new and modified files from the server. Is there a way to do this form OSX shell?
I would like to sync a local folder on my Mac to a remote ftp server. I only want to upload files changed since last sync. I would also like to download new and modified files from the server. Is there a way to do this form OSX shell?
Do you have ssh access? If so you should look at rsync. It won't work over FTP however.
From the command line:
Keep your eye on the trailing slashes, they make a difference
If you are looking for bi-directional sync, look at unison. It is basically a wrapper around rsync to add bi-directional support. Binaries are available at http://www.cis.upenn.edu/~bcpierce/unison/download.html One caveat to be aware of is you must run the same version on the client and server, so if you dont have the ability to install it on the remote site it is useless. In that case, rsync is probably installed on the remote site and you can probably run two rsync commands to move data each way. Just note that conflicts will get overwritten with rsync.
If it has to be FTP then AASync looks promising. It's a GUI based application but also can be scheduled and run in background. Maybe this is as good as being called by a shell.