src/Robo/Commands/Sync/SyncCommand.php
public function syncFiles() {
    $local_alias = '@' . $this->getConfigValue('drush.aliases.local');
    $remote_alias = '@' . $this->getConfigValue('drush.aliases.remote');
    $site_dir = $this->getConfigValue('site');

    $task = $this->taskDrush()
      ->alias('')
      ->uri('')
      ->drush('rsync')
      ->arg($remote_alias . ':%files/')
      ->arg($this->getConfigValue('docroot') . "/sites/$site_dir/files")
      ->option('exclude-paths', implode(':', $this->getConfigValue('sync.exclude-paths')));

    $result = $task->run();

    return $result;
  }
public function syncFiles() {
    $local_alias = '@' . $this->getConfigValue('drush.aliases.local');
    $remote_alias = '@' . $this->getConfigValue('drush.aliases.remote');
    $site_dir = $this->getConfigValue('site');

    $task = $this->taskDrush()
      ->alias('')
      ->uri('')
      ->drush('rsync')
      ->arg($remote_alias . ':%files/')
      ->arg($this->getConfigValue('docroot') . "/sites/$site_dir/files")
      ->option('exclude-paths', implode(':', $this->getConfigValue('sync.exclude-paths')));

    $result = $task->run();

    return $result;
  }
public function syncFiles ( ) { $ local_alias = '@' . $ this -> getConfigValue ( 'drush.aliases.local' ) ; $ remote_alias = '@' . $ this -> getConfigValue ( 'drush.aliases.remote' ) ; $ site_dir = $ this -> getConfigValue ( 'site' ) ; $ task = $ this -> taskDrush ( ) -> alias ( '' ) -> uri ( '' ) -> drush ( 'rsync' ) -> arg ( $ remote_alias . ':%files/' ) -> arg ( $ this -> getConfigValue ( 'docroot' ) . "/sites/$site_dir/files" ) -> option ( 'exclude-paths' , implode ( ':' , $ this -> getConfigValue ( 'sync.exclude-paths' ) ) ) ; $ result = $ task -> run ( ) ; return $ result ; }
Copies remote files to local machine.

@command drupal:sync:files

@aliases dsf sync:files

@validateDrushConfig
@executeInVm

@todo Support multisite.
Copies remote files to local machine .