wp-project-triage

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

WP Project Triage

WordPress项目诊断

When to use

使用场景

Use this skill to quickly understand what kind of WordPress repo you’re in and what commands/conventions to follow before making changes.
当你需要快速了解当前所处的WordPress代码仓库类型,以及在进行更改前应遵循的命令和约定时,使用此技能。

Inputs required

所需输入

  • Repo root (current working directory).
  • 仓库根目录(当前工作目录)。

Procedure

操作步骤

  1. Run the detector (prints JSON to stdout):
    • node skills/wp-project-triage/scripts/detect_wp_project.mjs
  2. If you need the exact output contract, read:
    • skills/wp-project-triage/references/triage.schema.json
  3. Use the report to select workflow guardrails:
    • project kind(s)
    • PHP/Node tooling present
    • tests present
    • version hints and sources
  4. If the report is missing signals you need, update the detector rather than guessing.
  1. 运行检测器(将JSON输出到标准输出):
    • node skills/wp-project-triage/scripts/detect_wp_project.mjs
  2. 若需要确切的输出规范,请阅读:
    • skills/wp-project-triage/references/triage.schema.json
  3. 使用报告选择工作流程防护规则:
    • 项目类型
    • 已有的PHP/Node工具
    • 已有的测试
    • 版本提示及来源
  4. 如果报告缺少你需要的信号,请更新检测器而非自行猜测。

Verification

验证

  • The JSON should parse and include:
    project.kind
    ,
    signals
    , and
    tooling
    .
  • Re-run after changes that affect structure/tooling (adding
    theme.json
    ,
    block.json
    , build config).
  • JSON应可解析,且包含:
    project.kind
    signals
    tooling
  • 在影响结构/工具的更改(如添加
    theme.json
    block.json
    、构建配置)后重新运行。

Failure modes / debugging

故障排查/调试

  • If it reports
    unknown
    , check whether the repo root is correct.
  • If scanning is slow, add/extend ignore directories in the script.
  • 如果报告显示
    unknown
    ,请检查仓库根目录是否正确。
  • 如果扫描速度慢,请在脚本中添加或扩展忽略目录。