Agent Skillsdartsim/dart › dart-changelog

dart-changelog

GitHub

DART项目变更日志管理技能,支持决定、起草、定稿及审计CHANGELOG.md条目。通过decide/draft/finalize/audit模式辅助工作流,确保发布说明规范与证据对齐。

.codex/skills/dart-changelog/SKILL.md dartsim/dart

触发场景

需要判断变更是否需记录到变更日志时 起草或修订尚未关联PR号的变更日志条目时 为已发布的PR添加链接并定稿条目时 审查发布章节是否存在缺失、重复或冗余条目时

安装

npx skills add dartsim/dart --skill dart-changelog -g -y
更多选项

非标准路径

npx skills add https://github.com/dartsim/dart/tree/main/.codex/skills/dart-changelog -g -y

不安装直接使用

npx skills use dartsim/dart@dart-changelog

指定 Agent (Claude Code)

npx skills add dartsim/dart --skill dart-changelog -a claude-code -g -y

安装 repo 全部 skill

npx skills add dartsim/dart --all -g -y

预览 repo 内 skill

npx skills add dartsim/dart --list

SKILL.md

Frontmatter
{
    "name": "dart-changelog",
    "description": "DART Changelog: decide, draft, finalize, or audit DART changelog entries"
}

dart-changelog

Use this skill in Codex to run the DART dart-changelog workflow. The editable workflow source currently lives in .claude/commands/, and this generated Codex skill is a generated Codex adapter entrypoint.

Invocation

  • Claude Code/OpenCode: /dart-changelog <arguments>
  • Codex: $dart-changelog <arguments>

Treat the text after the skill name as $ARGUMENTS. When the workflow references $1, $2, etc., map those to the positional values supplied by the user.

Command Body

Maintain DART changelog entries: $ARGUMENTS

Purpose

dart-changelog is the reusable changelog decision and writing routine. It is usually invoked by other DART workflows when they reach a changelog decision, not directly by users.

Use it to decide whether CHANGELOG.md needs an entry, draft an entry at the right level of detail, add a PR link after publication, or audit a release section for missing or over-detailed entries. Keep style, placement, evidence, and release-note density aligned with docs/onboarding/changelog.md.

Required Reading

@AGENTS.md @docs/onboarding/changelog.md @docs/onboarding/release-roadmap.md @docs/onboarding/release-management.md

Modes

Interpret $ARGUMENTS as one of these modes when present:

  • decide: determine whether the current change needs a changelog entry and record the reason for the PR checklist/body when no entry is needed.
  • draft: write or revise the entry before a PR number exists.
  • finalize: add the PR link or adjust the entry after a PR exists, keeping the follow-up local until explicit maintainer/user approval permits a push.
  • audit: scan a release section or PR set for missing, duplicate, over-detailed, misplaced, or stale entries.
  • release-audit: alias for audit when the caller is finalizing a release section through dart-release-packaging.

If no mode is given, infer the smallest mode that satisfies the caller's need.

Output Contract

Every run must leave the caller with a concise, pasteable decision note. Use this shape in the response, PR body draft, or handoff text:

Changelog decision:

- Mode: decide | draft | finalize | audit | release-audit
- Base evidence: <base ref or PR/release inspected>
- Scope evidence: <diff, PR, issue, or release section inspected>
- Decision: entry required | no entry required | entry deferred | audit only
- Target section: <release/category, or N/A>
- Entry text: <final or draft bullet, or N/A>
- PR-body note: <exact no-entry reason or follow-up, or N/A>
- Follow-up: <PR link, maintainer approval, release audit, or none>

For no entry required, the PR-body note must name the evidence-backed reason rather than just saying "not needed." For entry deferred, say exactly what is missing, usually the PR number or release target. For finalize, confirm the entry still matches nearby CHANGELOG.md style after adding the PR link.

Workflow

  1. Inspect the change and target:
    git status --short --branch
    git diff --stat
    git diff --cached --stat
    BASE_REF="$(gh pr view --json baseRefName --jq .baseRefName 2>/dev/null || true)"
    # If the caller or arguments name a release branch before PR creation, set
    # BASE_REF to that branch before falling back to automatic inference.
    if [ -z "$BASE_REF" ]; then
      CURRENT_BRANCH="$(git branch --show-current)"
      UPSTREAM_REF="$(git rev-parse --abbrev-ref --symbolic-full-name @{upstream} 2>/dev/null || true)"
      for REF in "$CURRENT_BRANCH" "${UPSTREAM_REF#origin/}"; do
        case "$REF" in
          main|release-*) BASE_REF="$REF"; break ;;
        esac
      done
    fi
    BASE_REF="${BASE_REF:-main}"
    git fetch origin "$BASE_REF"
    git diff --stat "origin/$BASE_REF...HEAD"
    gh pr diff --name-only 2>/dev/null || true
    gh pr list --head "$(git branch --show-current)"
    
    Use the base comparison or PR diff even when the worktree is clean. If a PR, issue, release, or target branch is named, inspect that live object before writing and prefer its base over the main fallback.
  2. Read docs/onboarding/changelog.md and the relevant CHANGELOG.md release section. Compare nearby bullets before drafting so wording, section choice, and level of detail match the current file.
  3. Decide whether an entry is required using the guide:
    • user-visible API, behavior, packaging, CI, docs workflow, AI-infra, simulation correctness, release, or migration impact usually needs an entry;
    • typo-only, formatting-only, generated-only, and tiny internal refactors usually do not.
  4. Record the decision with the Output Contract before modifying CHANGELOG.md or telling a caller to skip it. The decision must cite the diff, PR, issue, release section, or target branch that was inspected.
  5. When writing, start with the reader-visible outcome, not the implementation chore. Use one concise bullet, combine closely related changes, avoid author credits, and avoid one-bullet-per-PR diary style.
  6. Place the entry under the target branch's release section and nearest existing category. Do not create a new category for one PR unless the release shape genuinely needs it.
  7. Add the best evidence link:
    • if a PR number exists, use ([#1234](https://github.com/dartsim/dart/pull/1234));
    • if no PR number exists yet, draft without the link and leave the follow-up local until explicit approval permits another push or PR update.
  8. For release audits, consolidate noisy implementation ledgers, confirm breaking/removal/deprecation bullets name a migration or support lane, and preserve human-readable release notes over exhaustive history.
  9. Validate with the gate appropriate to the caller. For changelog-only edits, run the docs-only checks from docs/ai/verification.md; before any commit, run pixi run lint.

Caller Contract

Other workflows should call this routine whenever they touch behavior or docs that may need release notes. The caller keeps ownership of the overall task, validation, PR body, and approval boundary; dart-changelog owns the changelog decision, wording, placement, evidence-link hygiene, and the pasteable decision note that lets Claude, Codex, OpenCode, and manual contributors record the same outcome.

Output

Report:

  • the changelog decision note in the Output Contract shape above;
  • the drafted or finalized entry text and its CHANGELOG.md placement;
  • gates run (pixi run lint, docs-only checks) and their results;
  • any follow-up left local pending explicit maintainer/user approval.

版本历史

  • 51b2d25 当前 2026-07-11 18:25

    澄清AI工作流术语(#3289)

  • e0d13fd 2026-07-05 10:37

同 Skill 集合

.claude/skills/dart-architecture/SKILL.md
.claude/skills/dart-build/SKILL.md
.claude/skills/dart-ci/SKILL.md
.claude/skills/dart-contribute/SKILL.md
.claude/skills/dart-io/SKILL.md
.claude/skills/dart-python/SKILL.md
.claude/skills/dart-references/SKILL.md
.claude/skills/dart-test/SKILL.md
.claude/skills/dart-verify-sim/SKILL.md
.codex/skills/dart-analyze/SKILL.md
.codex/skills/dart-architecture/SKILL.md
.codex/skills/dart-audit-agent-compliance/SKILL.md
.codex/skills/dart-backport-pr/SKILL.md
.codex/skills/dart-benchmark-packet/SKILL.md
.codex/skills/dart-branch-cleanup/SKILL.md
.codex/skills/dart-build/SKILL.md
.codex/skills/dart-ci/SKILL.md
.codex/skills/dart-close-issue/SKILL.md
.codex/skills/dart-contribute/SKILL.md
.codex/skills/dart-deps/SKILL.md
.codex/skills/dart-docs-update/SKILL.md
.codex/skills/dart-downstream-fix/SKILL.md
.codex/skills/dart-execute-packet/SKILL.md
.codex/skills/dart-fix-ci/SKILL.md
.codex/skills/dart-fix-issue/SKILL.md
.codex/skills/dart-io/SKILL.md
.codex/skills/dart-manage-pr/SKILL.md
.codex/skills/dart-mechanical-refactor/SKILL.md
.codex/skills/dart-new-task/SKILL.md
.codex/skills/dart-next/SKILL.md
.codex/skills/dart-plan-update/SKILL.md
.codex/skills/dart-pr/SKILL.md
.codex/skills/dart-python/SKILL.md
.codex/skills/dart-references/SKILL.md
.codex/skills/dart-release-merge-main/SKILL.md
.codex/skills/dart-release-packaging/SKILL.md
.codex/skills/dart-resume/SKILL.md
.codex/skills/dart-retro/SKILL.md
.codex/skills/dart-retrospect/SKILL.md
.codex/skills/dart-review-pr/SKILL.md
.codex/skills/dart-test/SKILL.md
.codex/skills/dart-triage-issue/SKILL.md
.codex/skills/dart-ultrawork/SKILL.md
.codex/skills/dart-verify-sim/SKILL.md

元信息

文件数
0
版本
51b2d25
Hash
652435d7
收录时间
2026-07-05 10:37

首页 - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-07-14 13:55
浙ICP备14020137号-1 $访客地图$