On 10/19/06, Darin Perusich <[EMAIL PROTECTED]> wrote:
is there a way for rsync to create non-existing parent directories when syncing files to a destination? something similar to 'mkdir -p non-existing/directory'. i'm doing 'rsync -r /path/to/source /path/to/non-existing/directory', and the 'non-existing/directory' location doesn't exist.
Rsync will only create the top-level destination directory, not its parents. So just run an appropriate "mkdir -p" command before rsync. If this needs to happen on the remote host of a transfer over SSH, pass rsync something like --rsync-path="mkdir -p /path/to/non-existing/directory && rsync". Matt -- To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html