Codegyre/Robo — pull request #40 by boedah (2014-06-02 11:52:43+00:00)
Title: Feature/rsync task

Executes rsync in a flexible manner.

``` php
$this->taskRsync()
->fromPath('src/')
->toHost('localhost')
->toUser('dev')
->toPath('/var/www/html/app/')
->recursive()
->excludeVcs()
->checksum()
->wholeFile()
->verbose()
->progress()
->humanReadable()
->stats()
->run();
```

You could also clone the task and do a dry-run first:

``` php
$rsync = $this->taskRsync()
->fromPath('src/')
->toPath('example.com:/var/www/html/app/')
->archive()
->excludeVcs()
->progress()
->stats();

$dryRun = clone $rsync;
$dryRun->dryRun()->run();
if ('y' === $this->ask('Do you want to run (y/n)')) {
$rsync->run();
}
```