code: private function copyFiles($files, $source, $target, $roles, $vars)
      {
          foreach ($files as $file) {
              $from = $this->combine($source, $file['from']);
              $to = $this->combine($target, $roles[$file['role']]);
              $to = $this->combine($to, $file['to']);
              $tasks = $file['tasks'];
              $this->copyFile($from, $to, $tasks, $vars);
          }
      }
docs: Perform copy actions on files
  
  @param array $files array of copy actions ('from', 'to') with relative paths
  @param string $source path to source dir.
  @param string $target path to destination dir
  @param array $roles array [role => roleRoot] relative root for files having that role
  @param array $vars  list of values can be used for replacement tasks