Skip to content

v0.4.1

Latest

Choose a tag to compare

@mattyhansen mattyhansen released this 13 Jun 22:17
ce2a22c

gruff-php 0.4.1 - rule-rubric precision, enum-candidate retired, src namespace consolidation

Headline

0.4.1 focuses on rule-rubric precision: fewer false positives and fewer over-severe findings without disabling the rules that catch real maintainability problems.

Highlights

  • BREAKING: Removed modernisation.enum-candidate - Constant-only classes are no longer pushed toward enums.
  • Tighter rubrics (docs/naming/size/complexity/modernisation/dead-code) - Fewer false positives and over-severe findings; real waste still reports.
  • Constant PHPDoc is configurable - docs.missing-constant-phpdoc accepts local comments by default; require strict API PHPDoc via requirePhpdocForApiConstants / apiPathPatterns.
  • report rejects unknown rule filters - --include-rule/--exclude-rule typos fail fast (exit 2) up front, like analyse.
  • Namespace consolidation - src/ reorganised into six packages; public contracts unchanged, only direct internal imports change (GruffPhp\Rule\Rules\).

Upgrade

composer require --dev blundergoat/gruff-php:^0.4
vendor/bin/gruff-php --version   # gruff-php 0.4.1

Resetting gruff-php.yaml is required since a rubric was removed.

vendor/bin/gruff-php init --force