src/Folder.php
public static function copy($src, $dest, $force=false, $delete=false)
  {
    $src  = Path::clean($src);
    $dest = Path::clean($dest);
    
    $fs = new Filesystem();
    
    try {
      $fs->mirror($src, $dest, null, [ 'override' => $force, 'delete' => $delete, 'copy_on_windows' => true ]);
    } catch(IOExceptionInterface $e){
      throw new Exception(Helper::getTranslation('CANNOT_FIND_SOURCE').' '.$e->getPath());
    }
    
    return true;
  }
public static function copy($src, $dest, $force=false, $delete=false)
  {
    $src  = Path::clean($src);
    $dest = Path::clean($dest);
    
    $fs = new Filesystem();
    
    try {
      $fs->mirror($src, $dest, null, [ 'override' => $force, 'delete' => $delete, 'copy_on_windows' => true ]);
    } catch(IOExceptionInterface $e){
      throw new Exception(Helper::getTranslation('CANNOT_FIND_SOURCE').' '.$e->getPath());
    }
    
    return true;
  }
Mirrors a directory to another.

@param   string    $src    The path to the source folder
@param   string    $dest   The path to the destination folder
@param   bool      $force  Force copy
@throws   Exception