diff --git a/composer.json b/composer.json index 87c11f6c..e34c1173 100644 --- a/composer.json +++ b/composer.json @@ -105,15 +105,15 @@ "php": "^8.0" }, "require-dev": { - "phpstan/phpstan": "^1.5", + "phpstan/phpstan": "^1", "thecodingmachine/phpstan-strict-rules": "^1.0", "squizlabs/php_codesniffer": "^3.2", "phpunit/phpunit": "^10" }, "scripts": { "test": "phpunit", - "phpstan": "phpstan analyse lib -c phpstan.neon --level=max --no-progress -vvv", + "phpstan": "phpstan analyse", "cs-fix": "phpcbf", "cs-check": "phpcs" } -} \ No newline at end of file +} diff --git a/generator/composer.json b/generator/composer.json index 49def268..96d40856 100644 --- a/generator/composer.json +++ b/generator/composer.json @@ -19,11 +19,11 @@ "thecodingmachine/phpstan-strict-rules": "^1.0", "squizlabs/php_codesniffer": "^3.2", "php-coveralls/php-coveralls": "^2.1", - "phpstan/phpstan": "^1.5" + "phpstan/phpstan": "^1" }, "scripts": { "test": "vendor/bin/phpunit", - "phpstan": "phpstan analyse src -c phpstan.neon --level=max --no-progress -vvv", + "phpstan": "phpstan analyse", "cs-fix": "phpcbf", "cs-check": "phpcs" } diff --git a/generator/phpstan.neon b/generator/phpstan.neon index bf8cad2d..0dcbf845 100644 --- a/generator/phpstan.neon +++ b/generator/phpstan.neon @@ -1,4 +1,8 @@ parameters: + paths: + - ./src + # The level 9 is the highest level (with check for mixed type) + level: 8 ignoreErrors: includes: - - vendor/thecodingmachine/phpstan-strict-rules/phpstan-strict-rules.neon \ No newline at end of file + - vendor/thecodingmachine/phpstan-strict-rules/phpstan-strict-rules.neon diff --git a/phpstan.neon b/phpstan.neon index d6b61d51..73518de6 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -1,5 +1,9 @@ parameters: + paths: + - ./lib + # The level 9 is the highest level (with check for mixed type) + level: 8 ignoreErrors: # A lot of functions are in extensions so it is ok not to find those includes: - - vendor/thecodingmachine/phpstan-strict-rules/phpstan-strict-rules.neon \ No newline at end of file + - vendor/thecodingmachine/phpstan-strict-rules/phpstan-strict-rules.neon