AgentSkillsCN

tk-frontmatter

安全编辑 tk 工单 YAML 前言部分(文件修改/文件创建/别名设置)。

SKILL.md
--- frontmatter
name: tk-frontmatter
description: Edit tk ticket YAML frontmatter safely (files-modify/files-create/alias).

tk-frontmatter Skill

Resolve skill dir (for scripts)

bash
SKILL_DIR=".pi/skills/tk-frontmatter"
if [[ ! -d "$SKILL_DIR" ]]; then SKILL_DIR="pi/skills/tk-frontmatter"; fi

Locate ticket file

  • bash "$SKILL_DIR/scripts/locate-ticket.sh" (requires TICKET_ID)

Update frontmatter (example)

yaml
---
id: nw-5c46
alias: os-tk-0001-add-oauth-login.2
files-modify:
  - src/auth.ts
files-create:
  - src/types/Auth.ts
openspec_task_ref: "Task 2"
---

Rules:

  • Edit only YAML frontmatter between --- markers.
  • Preserve existing fields and formatting.
  • Leave ticket body unchanged.