GitHub - PhpCodeArcheology/PhpCodeArcheology: PHP static analysis for architecture & maintainability — 60+ metrics, complexity analysis, dependency graphs, git churn hotspots, and AI-ready MCP server.Read post
PhpCodeArcheology is a PHP static analysis tool focused on architecture and maintainability rather than type safety. It computes 60+ metrics including cyclomatic complexity, cognitive complexity, maintainability index, LCOM, and Halstead metrics across files, classes, methods, and functions. Key features include git churn hotspot detection, baseline management for legacy projects, test coverage integration (PHPUnit/Pest/Codeception with optional Clover XML), and multiple report formats (HTML, Markdown, JSON, SARIF, AI summary, Knowledge Graph). Notably, it is the first PHP static analysis tool with native MCP (Model Context Protocol) support, allowing AI assistants like Claude to query analysis results directly. It also generates CLAUDE.md project overviews for AI coding assistants and supports CI/CD pipelines with configurable exit codes.
3 Comments
Sort: