File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -233,20 +233,19 @@ function getVersion($cmd)
233233echo "Setup process is successfully completed! \n" ;
234234
235235// PHP > 8.4 Fixing
236- if (version_compare ( $ phpVersion , ' 8.4.0 ' , ' >= ' ) ) {
237- echo "\033[0;36mℹ️ PHP >= 8.4 detected, installing php-cs-fixer... \033[0m \n" ;
236+ if (PHP_VERSION_ID >= 80400 ) {
237+ echo "\033[0;36m PHP >= 8.4 detected, installing php-cs-fixer... \033[0m \n" ;
238238
239- // Installing php-cs-fixer as a dev dependency
240239 passthru ("composer require --dev friendsofphp/php-cs-fixer " );
241240
242- // Run the fixer
243241 if (stripos (PHP_OS , 'WIN ' ) === 0 ) {
244242 passthru (". \\vendor \\bin \\php-cs-fixer fix " );
245243 } else {
246244 passthru ("./vendor/bin/php-cs-fixer fix " );
247245 }
246+
248247 echo "\033[0;32m Code style fixed with php-cs-fixer. \033[0m \n" ;
249248} else {
250- echo "\033[0;33m PHP version < 8.4 → skipping php-cs-fixer installation . \033[0m \n" ;
249+ echo "\033[0;33m PHP version < 8.4 → skipping php-cs-fixer. \033[0m \n" ;
251250}
252251
You can’t perform that action at this time.
0 commit comments