4 Filesystem provides basic utility to manipulate the file system:
9 use Symfony\Component\Filesystem\Filesystem;
11 $filesystem = new Filesystem();
13 $filesystem->copy($originFile, $targetFile, $override = false);
15 $filesystem->mkdir($dirs, $mode = 0777);
17 $filesystem->touch($files, $time = null, $atime = null);
19 $filesystem->remove($files);
21 $filesystem->chmod($files, $mode, $umask = 0000, $recursive = false);
23 $filesystem->chown($files, $user, $recursive = false);
25 $filesystem->chgrp($files, $group, $recursive = false);
27 $filesystem->rename($origin, $target);
29 $filesystem->symlink($originDir, $targetDir, $copyOnWindows = false);
31 $filesystem->makePathRelative($endPath, $startPath);
33 $filesystem->mirror($originDir, $targetDir, \Traversable $iterator = null, $options = array());
35 $filesystem->isAbsolutePath($file);
41 You can run the unit tests with the following command:
43 $ cd path/to/Symfony/Component/Filesystem/
44 $ composer.phar install --dev