Static Code Analysis: Judging a Forest by Its Trees
summary
Automates boring code-review chores by running concrete tools: ECS combines PHP CS Fixer and PHP_CodeSniffer to fix style, PHPStan levels 0–8 to tune strictness, Psalm for extended typing, PHP Insights for CI-friendly colorized output, Deptrac to map dependencies and a migration that cuts wrong module links by ~40% in weeks, PhpMetrics (Twig runs in ~10s) for cyclomatic and coupling scores, custom PHPStan rules enforce an @decoratable contract, and composer-bin-plugin encapsulates tooling so it works locally and in CI.
AI-written summary · about
chapters (24)
- 0:00Introduction
- 0:33Trees
- 2:45Readability
- 5:43PHP Trees
- 8:25PHP Stan
- 12:50Extended Type System
- 14:17Type Arrays
- 15:44Objectlike Arrays
- 17:16Type Safety
- 19:55Metrics
- 20:31Track Depth
- 21:15Track Module
- 22:52Dependencies
- 25:15Crosscutting
- 26:13PHP Metrics
- 33:54Maintainability
- 35:38PHP Insights
- 38:48PHP Tools
- 41:01Key takeaway
- 41:44composable plugin
- 43:10vendorbin
- 44:31makefile
- 45:27aesthetic analysis
- 45:54alternatives








