OSX SSH rsync - Keep remote directory up to date
Rise to the top 3% as a developer or hire one of them at Toptal: https://topt.al/25cXVn
--------------------------------------------------
Music by Eric Matyas
https://www.soundimage.org
Track title: Puzzle Game 5
--
Chapters
00:00 Osx Ssh Rsync - Keep Remote Directory Up To Date
00:30 Answer 1 Score 0
01:10 Accepted Answer Score 1
01:24 Answer 3 Score 0
01:42 Answer 4 Score 1
02:09 Thank you
--
Full question
https://superuser.com/questions/232060/o...
--
Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...
--
Tags
#macos #ssh #rsync #scp #winscp
#avk47
ACCEPTED ANSWER
Score 1
Your best bet is probably to use Folder Actions and adapting the new item alert script to your needs, issuing a call to the command line utility of your choice.
ANSWER 2
Score 1
You may use launchd instead of folder actions (to get some sample code just google for: launchd folder watcher).
You may then combine you launchd folder watcher item with a scp script similar to this one.
Or, use rsync over ssh like so:
rsync -urltv --delete -e ssh /path/to/dir othermachine:/path/to/dir
For a commercial cross-platform software solution see GoodSync.
ANSWER 3
Score 0
Check out Transmit by Panic. From one of their blog posts, a commenter said:
One of my favorite features, that some people may not know, when you open a document into a certain application in Transmit (let’s say an .html file into BBEdit) then edit the document and Save it; Transmit automatically uploads it back to the server to the same file, no questions asked. It works wonders when making websites and editing CSS. Also convenient to make small corrections in images through Photoshop. You can also handle how Transmit deals with certain file extensions through the Prefs.
ANSWER 4
Score 0
I have come across a ruby script that does what you need, but it will take a little adapting.
Description:
rsync whenever the directory the script is in changes using the OS X FSEvents API
https://gist.github.com/149491