Skip to content

Commit

Permalink
Create PHPStan baseline for PHP 8+
Browse files Browse the repository at this point in the history
  • Loading branch information
AdamVyborny committed Apr 4, 2023
1 parent 1a1f7a6 commit c9f72cd
Show file tree
Hide file tree
Showing 3 changed files with 515 additions and 1 deletion.
18 changes: 18 additions & 0 deletions ignore-by-php-version.neon.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

use PHPStan\DependencyInjection\NeonAdapter;

$adapter = new NeonAdapter();

$config = [];
if (PHP_VERSION_ID >= 80000) {
$config = array_merge_recursive($config, $adapter->load(__DIR__ . '/phpstan-baseline-8+.neon'));
} else {
$config = array_merge_recursive($config, $adapter->load(__DIR__ . '/phpstan-baseline.neon'));
}

$config['parameters']['phpVersion'] = PHP_VERSION_ID;

return $config;
Loading

0 comments on commit c9f72cd

Please sign in to comment.