Preventing rsync from polluting a destination directory during transfer

by

(e.g. When the directory that rsync is copying to is, itself, a publicly visible directory.)

The magic option is -T / –temp-dir and note that if you don’t want it to be a sub-directory of the target (which is probably the whole point if you’re trying to avoid contaminating a publicly visible directory) you’ll need to specify an absolute path (starts with ‘/’) rather than a relative one.

This is obvious in retrospect except that I’d assumed that –partial did this (it doesn’t).

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: