There is FreeFileSync which shows the idea of a bi-directional, automatically-file-watching file sync tool, and is quite nice -- apart from that it's unclear how to automate it. There is also this thing called rsync which people mention all the time, but seems a bit mysterious.

rsync

OK so I basically sat down and RTFM. Turns out that it was quite simple: it's kinda like cp (or rather, scp), except that it can work with remote machines, by default via SSH, and has smart algorithms that moves only deltas / "patches", which speeds things up a lot.

So basically, all rsync does is copy files. It seems good for backing stuff up, especially when being used as a cron job -- but for bi-directional syncing, which is our goal here, that's not enough. Enter unison.

Unison

Unison is, as is claims, a "file synchronizer". Reading their manual a bit, this seems like the exact piece of the puzzle we want (in order to achieve bi-di sync).

So, trying out their simple local usage tutorial (anchor #local on the same page), I got a general feeling of Unison. Although it believably seems configurable and scriptable, the default behaviour is highly interactive (i.e. to the keypress -- response is made before I even hit after a keypress).</p>

Again, we can cron; but is there something that perhaps gives (at least semi-) real-time "watching" and triggers Unison (or rsync) automatically? Well, enter lsyncd.

Lsyncd

Lsyncd seems to be sort of like watch, but calls either rsync or a command specified in a configuration file upon the watched files being changed.

Disclaimer

I was a bit too lazy to try putting Lsyncd & rsync or Lsyncd & Unison together; my primary use-case really is just backing up a directory from my laptop into my external hard drive -- which is quite satisfiable by manually-triggered uni-directional backup -- which currently I'm (shamefully) not actually doing in any systematic way at all. I'll probably try out those fancier setups after I've rsyncd for a while.