Closed ruudk closed 1 year ago
I'm solving similar situation with different PHPStan config file with different rules. For example
https://github.com/spaze/michalspacek.cz/blob/5f1606dc130823f0b717b14eea846a3e70452a65/site/composer.json#L80 and https://github.com/spaze/michalspacek.cz/blob/master/site/phpstan-vendor.neon
It might make sense as there's already something similar for params (allowExceptParams
et al.). If the extra config doesn't help, then it might be worthwhile but maybe it should follow the "allowExcept" naming pattern.
I've just released this in 2.9.0, hope it's still useful (realized today it is useful for me too 😊)
I'm sorry but I can't remember why I wanted to use this back in 2021... But thanks for fixing it. Maybe I'll use it in the future 😊
It would be great if I could enforce some rules that only apply in some directories.
Currently, the only way to get that working is to construct a list of all options using wildcards, and then exclude the target from it. Not very ideal / scalable.
What do you think, would this be worth adding? Of course I can work on a PR to address it.