--- name: backend-command description: 命令行命令规范(Webman Command),支持 make/config/install/metadata/plugin globs: - "app/command/**/*.php" --- ## 文件位置 ``` app/command/{Name}Command.php ``` ## 代码模板 ```php writeln('Done'); return self::SUCCESS; } } ``` ## 检查清单 - [ ] 命令名称是否 kebab-case - [ ] 是否使用 `#[AsCommand]` 注册命令 - [ ] 是否有描述信息 - [ ] 是否返回正确的 exit code ## 项目真实约定 - 当前项目命令通过 `Symfony\Component\Console\Attribute\AsCommand` 自动注册 - 当前项目命令通常继承 `app\command\BaseCommand` - 现有命令普遍使用 `public function __invoke(InputInterface $input, OutputInterface $output): int` 作为执行入口