spec-driven-maintenance

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese
You are helping the user manage the manual maintenance workflow.
你正在协助用户管理手动维护工作流。

Prerequisites

前置条件

The target project must already contain
.spec-driven/
at the project root. Before proceeding, verify:
ls .spec-driven/
If this fails, run
/spec-driven-init
first.
目标项目必须已经在根目录下包含
.spec-driven/
目录。 继续操作前,请先验证:
ls .spec-driven/
如果执行失败,请先运行
/spec-driven-init

Steps

操作步骤

  1. Choose the maintenance action:
    • Run the maintenance workflow manually right now
    • Inspect or adjust the maintenance config
  2. Read existing maintenance assets when present:
    • .spec-driven/maintenance/config.json
    • Relevant README or project docs that define lint/test/typecheck commands
  3. For a manual maintenance run — run:
    node {{SKILL_DIR}}/scripts/spec-driven.js run-maintenance [path]
    Then report whether the run:
    • failed because the maintenance config is missing or invalid
    • skipped because the repo was dirty, had no configured checks, or already had an active maintenance change
    • completed cleanly because all configured checks already passed
    • found unfixable failures
    • became blocked during fix, archive, commit, or branch-restore work
    • created a maintenance branch/change and repaired the configured checks
  4. When editing config:
    • Keep
      checks
      limited to commands the repo explicitly supports
    • Only add
      fixCommand
      for deterministic, low-risk repairs
    • Use
      changePrefix
      ,
      branchPrefix
      , and
      commitMessagePrefix
      only when the repo needs custom naming
  1. 选择维护操作
    • 立即手动运行维护工作流
    • 检查或调整维护配置
  2. 读取已有的维护资源(如果存在)
    • .spec-driven/maintenance/config.json
    • 定义了lint/test/typecheck命令的相关README或项目文档
  3. 如果要手动运行维护,执行以下命令:
    node {{SKILL_DIR}}/scripts/spec-driven.js run-maintenance [path]
    随后报告运行结果属于以下哪种情况:
    • 因维护配置缺失或无效运行失败
    • 因仓库存在未提交变更、无已配置的检查规则或已有活跃的维护变更而跳过
    • 所有已配置检查均已通过,运行顺利完成
    • 发现无法修复的故障
    • 在修复、归档、提交或分支恢复环节被阻塞
    • 已创建维护分支/变更并修复了所有已配置的检查项
  4. 编辑配置时注意事项
    • checks
      仅保留仓库显式支持的命令
    • 仅为确定性、低风险的修复操作添加
      fixCommand
    • 仅当仓库需要自定义命名规则时,才使用
      changePrefix
      branchPrefix
      commitMessagePrefix

Rules

规则

  • Do not add speculative
    fixCommand
    entries for semantically ambiguous test failures
  • Treat the maintenance config as the source of truth for allowed maintenance fixes
  • If a maintenance run leaves a blocked change behind, report that clearly instead of pretending the repair succeeded
  • 不要为语义不明确的测试失败添加推测性的
    fixCommand
    条目
  • 维护配置是允许执行的维护修复操作的唯一可信来源
  • 如果维护运行后留下了被阻塞的变更,请明确上报,不要假装修复成功