This skill provides intelligent PHPStan static analysis and fixing through specialized agent delegation.
Agent Delegation Strategy
This skill delegates to specialized agents via the Task tool:
php-qa-ci_phpstan-runner agent (haiku model) - Runs analysis and parses results
php-qa-ci_phpstan-fixer agent (sonnet model) - Analyzes and fixes errors
Escalation - Uses opus model or asks human for stubborn issues
Workflow
When User Says: "Run PHPStan"
Launch runner agent:
Use Task tool:
description: "Run PHPStan analysis"
subagent_type: "php-qa-ci_phpstan-runner"
prompt: "Run PHPStan static analysis and provide summary"
Receive runner output with log location
If errors detected:
Launch fixer agent:
Use Task tool:
description: "Fix PHPStan errors"
subagent_type: "php-qa-ci_phpstan-fixer"
prompt: "Fix errors in log: {log_path}"
After fixes applied, re-run via runner agent
Repeat cycle until:
Analysis passes → Success
Same errors persist 2+ times → Escalate to opus or human
User intervention needed → Ask user
When User Says: "Fix the PHPStan errors"
Check if recent log exists in var/qa/phpstan_logs/
If log found:
Launch fixer agent directly with log path
If no log:
Launch runner agent first to generate log
Then launch fixer agent
Escalation Triggers
Launch opus model or ask human when:
Fixer agent reports "cannot fix" for same error 2+ times
Architecture questions arise (design patterns, type hierarchies)
User explicitly requests explanation of errors
Runner Agent Reference
The phpstan-runner agent (haiku model) handles:
PHPStan execution with proper configuration
Log parsing for error patterns
Concise summary generation
See .claude/agents/php-qa-ci_phpstan-runner.md for agent implementation details.
Fixer Agent Reference
The phpstan-fixer agent (sonnet model) handles:
Log file discovery and parsing
Error grouping by pattern
Fix implementation for common PHPStan issues
Verification that fixes resolve issues
See .claude/agents/php-qa-ci_phpstan-fixer.md for agent implementation details.
Converted and distributed by TomeVault — claim your Tome and manage your conversions.
1---2name: longtermsupport-php-qa-ci-phpstan-runner3description: PHPStan Runner Skill4---56# PHPStan Runner Skill78This skill provides intelligent PHPStan static analysis and fixing through specialized agent delegation.910## Agent Delegation Strategy1112This skill delegates to specialized agents via the Task tool:13141. **php-qa-ci_phpstan-runner agent (haiku model)** - Runs analysis and parses results152. **php-qa-ci_phpstan-fixer agent (sonnet model)** - Analyzes and fixes errors163. **Escalation** - Uses opus model or asks human for stubborn issues1718## Workflow1920### When User Says: "Run PHPStan"21221. Launch runner agent:23 ```24 Use Task tool:25 description: "Run PHPStan analysis"26 subagent_type: "php-qa-ci_phpstan-runner"27 prompt: "Run PHPStan static analysis and provide summary"28 ```29302. Receive runner output with log location31323. If errors detected:33 - Launch fixer agent:34 ```35 Use Task tool:36 description: "Fix PHPStan errors"37 subagent_type: "php-qa-ci_phpstan-fixer"38 prompt: "Fix errors in log: {log_path}"39 ```40414. After fixes applied, re-run via runner agent42435. Repeat cycle until:44 - Analysis passes → Success45 - Same errors persist 2+ times → Escalate to opus or human46 - User intervention needed → Ask user4748### When User Says: "Fix the PHPStan errors"49501. Check if recent log exists in var/qa/phpstan_logs/51522. If log found:53 - Launch fixer agent directly with log path54553. If no log:56 - Launch runner agent first to generate log57 - Then launch fixer agent5859### Escalation Triggers6061Launch opus model or ask human when:62- Fixer agent reports "cannot fix" for same error 2+ times63- Architecture questions arise (design patterns, type hierarchies)64- User explicitly requests explanation of errors6566## Runner Agent Reference6768The phpstan-runner agent (haiku model) handles:69- PHPStan execution with proper configuration70- Log parsing for error patterns71- Concise summary generation7273See `.claude/agents/php-qa-ci_phpstan-runner.md` for agent implementation details.7475## Fixer Agent Reference7677The phpstan-fixer agent (sonnet model) handles:78- Log file discovery and parsing79- Error grouping by pattern80- Fix implementation for common PHPStan issues81- Verification that fixes resolve issues8283See `.claude/agents/php-qa-ci_phpstan-fixer.md` for agent implementation details.8485---86> Converted and distributed by [TomeVault](https://tomevault.io/claim/longtermsupport) — claim your Tome and manage your conversions.87<!-- tomevault:4.0:skill_md:2026-04-15 -->
Run npx skillmds@latest add tomevault-io/longtermsupport-php-qa-ci-phpstan-runner in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
PHPStan Runner Skill It is listed under Coding & Dev Tools on SkillMD.
This skill has not completed SkillMD's automated safety review yet. Independent scanners report: SkillSpector: PASS, Skill Scanner: PASS. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
tomevault-io (@tomevault-io) published this skill. Their other Agent Skills are listed on their SkillMD profile.