Open peterjaap opened 1 year ago
Wait, I think I found a bug. This line should read 'warnings', not 'errors'. And the next one should read 'fixable', not 'errors';
This causes the baseliner to skip warnings when there are 0 errors.
LOL there already is a PR made SIX DAYS ago while this bug has been in here since January 2020!
https://github.com/isaaceindhoven/php-code-sniffer-baseliner/pull/11
PR is merged now and part of v2.3.1. Please let me now if this issue can be closed.
Our CI fails when phpcs returns warnings, however, this package does not add warnings to the baseline, only errors.
So when I run the baseliner I get;
But when I run phpcs;
And it finds a lot of warnings and exits with non-zero error code, making our pipeline fail.
I could add
<config name="ignore_warnings_on_exit" value="1" />
tophpcs.xml
, but then there's no record of these errors in the baseline, which is what I prefer.Is it possible to add a flag to also create a baseline for phpcs warnings, not just errors?