diff --git a/composer.json b/composer.json index 1d608d0..414df64 100644 --- a/composer.json +++ b/composer.json @@ -12,7 +12,8 @@ "symfony/dependency-injection": "6.1.*", "symfony/finder": "^6.2", "symplify/package-builder": "^11.1", - "webmozart/assert": "^1.11" + "webmozart/assert": "^1.11", + "symfony/filesystem": "^6.3" }, "require-dev": { "rector/rector": "^0.15.13", diff --git a/src/FileSystem/PathHelper.php b/src/FileSystem/PathHelper.php index fa5e004..47cd9a4 100644 --- a/src/FileSystem/PathHelper.php +++ b/src/FileSystem/PathHelper.php @@ -4,14 +4,13 @@ namespace Rector\RectorGenerator\FileSystem; -use Symplify\SmartFileSystem\SmartFileSystem; +use Symfony\Component\Filesystem\Filesystem; final class PathHelper { public static function getRelativePathFromDirector(string $filePath, string $directory): string { - $smartFileSystem = new SmartFileSystem(); - + $smartFileSystem = new Filesystem(); $relativeFilePath = $smartFileSystem->makePathRelative($filePath, (string) realpath($directory)); return rtrim($relativeFilePath, '/');