路由器
- 作者仓库星标 1,627
- 作者仓库 agent-skills
- 领域
- 安全
- 作者声明的智能体
- 未找到明确声明;不据此推断已兼容或已测试
- 静态检查
- 88 / 100 · 启发式扫描,不代表运行安全
- 运行环境证据
- 未执行;当前没有隔离运行测试证据
- 作者 / 版本 / 许可证
- @WordPress · 未声明许可证
- 上下文用量评级
- 低消耗
- 接入复杂程度
- 即装即用
- 是否需要外部接口密钥
- 不需要
- 兼容的系统
- macOS · Linux · Windows
- 运行环境要求
- Node.js
- 检测到的文件与系统行为
-
- 只读
- 允许写入 / 修改
- 网络行为
- 仅限本地
- 安装命令数
- 无(仅作为资料)
需要注意: 未声明工具权限范围;实际权限由运行环境决定。
# WordPress Router
## When to use
Use this skill at the start of most WordPress tasks to:
- identify what kind of WordPress codebase this is (plugin vs theme vs block theme vs WP core checkout vs full site),
- pick the right workflow and guardrails,
- delegate to the most relevant domain skill(s).
## Inputs required
- Repo root (current working directory).
- The user’s intent (what they want changed) and any constraints (WP version targets, WP.com specifics, release requirements).
## Procedure
1. Run the project triage script:
- `node skills/wp-project-triage/scripts/detect_wp_project.mjs`
2. Read the triage output and classify:
- primary project kind(s),
- tooling available (PHP/Composer, Node, @wordpress/scripts),
- tests present (PHPUnit, Playwright, wp-env),
- any version hints.
3. Route to domain workflows based on user intent + repo kind:
- For the decision tree, read: `skills/wordpress-router/references/decision-tree.md`.
4. Apply guardrails before making changes:
- Confirm any version constraints if unclear.
- Prefer the repo’s existing tooling and conventions for builds/tests.
## Verification
- Re-run the triage script if you create or restructure significant files.
- Run the repo’s lint/test/build commands that the triage output recommends (if available).
## Failure modes / debugging
- If triage reports `kind: unknown`, inspect:
- root `composer.json`, `package.json`, `style.css`, `block.json`, `theme.json`, `wp-content/`.
- If the repo is huge, consider narrowing scanning scope or adding ignore rules to the triage script.
## Escalation
- If routing is ambiguous, ask one question:
- “Is this intended to be a WordPress plugin, a theme (classic/block), or a full site repo?”
章节与文件索引
按说明文件中的顺序排列。
何时使用
需要输入
程序
验证
故障模式/调试
文件/命令 -> node skills/wp-project-triage/scripts/detect_wp_project.mjs · skills/wordpress-router/references/decision-tree.md · kind: unknown · composer.json · package.json · style.css · block.json · theme.json
内容校验值 -> b41cfd7c2e89
当前原文的自动摘译,尚未人工审校。
何时使用
在大多数 WordPress 任务开始时使用此技能来:确定这是什么类型的 WordPress 代码库(插件、主题、块主题、WP 核心结账、完整站点),选择正确的工作流程和护栏,委托给最相关的领域技能。
需要输入
存储库根目录(当前工作目录)。用户的意图(他们想要更改的内容)和任何约束(WP 版本目标、WP.com 细节、发布要求)。
程序
运行项目分类脚本:
node skills/wp-project-triage/scripts/detect_wp_project.mjs读取分类输出并分类:主要项目类型、可用工具(PHP/Composer、Node、@wordpress/scripts)、验证
如果您创建或重组重要文件,请重新运行分类脚本。运行分类输出建议的存储库的 lint/test/build 命令(如果可用)。
故障模式/调试
如果分类报告
kind: unknown,请检查:根composer.json、package.json、style.css、block.json、theme.json、wp-content/。如果存储库很大,请考虑缩小扫描范围或向分类脚本添加忽略规则。