Rsync from a third host?

Warren Oates warren.oates at gmail.com
Tue Nov 4 20:27:31 GMT 2008


On Tue, Nov 4, 2008 at 2:33 PM, Warren Oates <warren.oates at gmail.com> wrote:

> You'll have to use an expect script for that, something like this one:
>
>  #!/usr/bin/expect -f
>
>  ## Note: set crontab's $PATH to search /usr/local/bin (or wherever
> you've installed rsync 3) first
>  spawn rsync -az --delete
> wife at 192.168.0.107:~/Documents/Eudora?Folder/ /Volumes/Backups/Eudora\
> Folder
>  expect "*?assword:*"
>  send  "********\r"
>  set timeout -1
>  expect eof
>
> This is instructive in another way  -- both the sender and receiver
> are Intel OS X 10.5.5; note how rsync handles spaces in filenames
> compared to to the filesystem itself.

Well, that got totally mangled, didn't it.

<proper>

#!/usr/bin/expect -f

## Note: set crontab's $PATH to search /usr/local/bin (or wherever
you've installed rsync 3) first

## all on one line, space after "?Folder/"
## I hate gmail sometimes
spawn rsync -az --delete wife at host:~/Documents/Eudora?Folder/
/Volumes/Backups/Eudora\ Folder
## end of that line

expect "*?assword:*"
send  "********\r"
set timeout -1
expect eof

</proper>
-- 
W. Oates


-- 
W. Oates


More information about the rsync mailing list