matesofmate/phpstan-extension
Composer 安装命令:
composer require matesofmate/phpstan-extension
包简介
PHPStan extension for Symfony AI Mate providing AI assistants with efficient static analysis tools
README 文档
README
Token-efficient PHPStan analysis tools for AI assistants. This package runs PHPStan and returns encoded structured results geared toward debugging and iteration.
Features
- analyse the full project or a selected file or directory
- clear PHPStan result cache
- three consistent compact output modes
- automatic configuration detection
Installation
composer require --dev matesofmate/phpstan-extension vendor/bin/mate init
In current AI Mate setups, extension discovery is handled automatically after Composer install and update. Run vendor/bin/mate discover when you want to refresh discovery artifacts such as mate/AGENT_INSTRUCTIONS.md.
Useful Mate commands:
vendor/bin/mate debug:extensions vendor/bin/mate debug:capabilities vendor/bin/mate mcp:tools:list --extension=matesofmate/phpstan-extension
Use the generated wrapper for Codex:
./bin/codex
Custom Command Configuration
If PHPStan must run through Docker or another wrapper command, configure matesofmate_phpstan.custom_command.
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator; return static function (ContainerConfigurator $container): void { $container->parameters()->set('matesofmate_phpstan.custom_command', [ 'docker', 'compose', 'exec', 'php', 'vendor/bin/phpstan', ]); };
Requirements
- PHP 8.2+
- Symfony AI Mate 0.8+ required
- PHPStan 2.x in the target project
Available Tools
phpstan-analysephpstan-clear-cache
This package returns encoded strings through Mate's core ResponseEncoder. Install the suggested helgesverre/toon package if you want TOON responses; otherwise the same payload falls back to JSON.
Output Modes
defaultsummarydetailed
Development
composer install
composer test
composer lint
composer fix
License
MIT
统计信息
- 总下载量: 4.74k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2026-01-11