diff --git a/phpcs.xml.dist b/phpcs.xml.dist
index 85673f5..56da6f5 100644
--- a/phpcs.xml.dist
+++ b/phpcs.xml.dist
@@ -6,8 +6,18 @@
+
+
+
+
+
+
+
+ /src/Plugin\.php
+ /res/deploy\.tpl\.php
+
/src/Plugin\.php
@@ -20,7 +30,7 @@
/src/Plugin\.php
-
+
/res/deploy\.tpl\.php
diff --git a/src/Plugin.php b/src/Plugin.php
index a65b78c..25a9c14 100644
--- a/src/Plugin.php
+++ b/src/Plugin.php
@@ -57,7 +57,7 @@ public function activate( Composer $composer, IOInterface $io ): void {
$config = $this->composer->getConfig();
- $this->rootDir = dirname( $config->getConfigSource()->getName() );
+ $this->rootDir = \dirname( $config->getConfigSource()->getName() );
}
/**
@@ -116,14 +116,14 @@ public function copyDeployerConfig( PackageEvent $event ): void {
} elseif ( $operation instanceof UpdateOperation ) {
$package = $operation->getTargetPackage();
} else {
- throw new \Exception( 'Unknown operation: ' . \get_class( $operation ) );
+ throw new \Exception( 'Unknown operation: ' . \get_class( $operation ) ); // phpcs:ignore SlevomatCodingStandard.Classes.ModernClassNameReference.ClassNameReferencedViaFunctionCall -- Switch to $operation::class when PHP 8.0 is minimum.
}
if ( self::PLUGIN_PACKAGE_NAME !== $package->getName() ) {
return;
}
- $source = dirname( __DIR__ ) . '/res/deploy.tpl.php';
+ $source = \dirname( __DIR__ ) . '/res/deploy.tpl.php';
$dest = $this->rootDir . '/deploy.php';
$copied = copy( $source, $dest );