From f86fc16d3f3f2bfe765d9f2ed440d302049ed4fb Mon Sep 17 00:00:00 2001 From: Molkobain Date: Thu, 13 Nov 2025 19:54:43 +0100 Subject: [PATCH] =?UTF-8?q?N=C2=B08796=20-=20Optimize=20PHP=20CS=20Fixer?= =?UTF-8?q?=20files=20finder?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/php-code-style/.php-cs-fixer.dist.php | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/tests/php-code-style/.php-cs-fixer.dist.php b/tests/php-code-style/.php-cs-fixer.dist.php index 6456c3dd9..22c91495a 100644 --- a/tests/php-code-style/.php-cs-fixer.dist.php +++ b/tests/php-code-style/.php-cs-fixer.dist.php @@ -5,8 +5,20 @@ $APPROOT = dirname(__DIR__, 2); echo $APPROOT; $finder = PhpCsFixer\Finder::create() ->in($APPROOT) - ->exclude(['oql', 'data', 'extensions']) - ->notPath(['/env-*/', '/cache-*/', 'lib', 'vendor', 'node_modules', 'config-itop', 'php-static-analysis']) + ->exclude([ + 'core/oql', + 'data', + 'extensions', + 'lib', + 'node_modules', + ]) + ->notPath([ + // Exclude environment folders based on a regex as we can't use a regex in ->exclude() + '|^env-(.*)|', + // Exclude third-party sub-folders + 'vendor', + 'node_modules' + ]) ; $config = new PhpCsFixer\Config();