Skip to content

Commit

Permalink
Conditional baseline
Browse files Browse the repository at this point in the history
  • Loading branch information
kubk committed Apr 19, 2024
1 parent 7a4e497 commit 7e342d8
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
10 changes: 10 additions & 0 deletions phpstan-baseline.neon.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?php declare(strict_types = 1);

$includes = [];
if (PHP_VERSION_ID >= 80200) {
$includes[] = __DIR__ . '/baseline-8.1.neon';
}
$config = [];
$config['includes'] = $includes;

return $config;
2 changes: 1 addition & 1 deletion phpstan.neon
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
includes:
- phpstan-baseline.neon
- phpstan-baseline.neon.php

parameters:
level: 6
Expand Down

0 comments on commit 7e342d8

Please sign in to comment.