updateversion

A release-preparation command for the UnitySkills project. It checks the project state, updates the required version information, and prepares a changelog for a stable semantic version such as 2.6.0.

In plain words
What is it for?
Use it to prepare a publishable version candidate on the beta branch, verify repository and GitHub CLI conditions, update approved version locations, and generate release notes.
Why use it?
It reduces mistakes when preparing a new release, such as using an invalid version or working from an outdated branch. It does not create a Git tag or GitHub Release, and it does not notify installed users.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/besty0728/unity-skills/updateversion
Clone the repo
git clone --depth 1 https://github.com/Besty0728/Unity-Skills

Made for: Claude Code.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,209 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.03209
Opus 5 $0.00000 $0.01605
Sonnet 5 $0.00000 $0.00642
Haiku 4.5 $0.00000 $0.00321

Measured 2d ago against content hash fb2fb28e615c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

updateversion scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/updateversion.md · 224 lines

How it starts

The opening of the file, as written. The whole thing — 224 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Update Version — 安全更新项目版本 + 生成 CHANGELOG

你是 UnitySkills 项目的版本更新助手。此命令只负责准备一个可发布的版本候选;它不会创建 tag 或 GitHub Release,也不会立即向已安装用户发送更新提醒。

Unity 内的更新提醒使用 SkillsLogger.Version 与 GitHub releases/latest 的稳定 Release 比较。只有正式发布新的非 draft、非 prerelease GitHub Release 后,用户才会看到更新横幅,并跳转到该版本的 /releases/tag/v{VERSION} 页面。

输入

用户必须提供不带 v 的稳定语义版本号,例如 /updateversion 2.6.0

  • 只接受严格的 MAJOR.MINOR.PATCH
  • 不接受 v2.6.02.62.6.0-beta.1 或四段版本号。
  • 未提供或格式不合法时停止,并提示:/updateversion <新版本号>

步骤 1:远端与版本线预检查

  1. 确认当前在 beta 分支;不在则停止。
  2. 确认 GitHub CLI 已登录:
    gh auth status
    
  3. 获取最新远端引用。任何 fetch 失败都必须停止,不能用过期的本地引用继续判断:
    git fetch origin main beta --tags
    
  4. 检查工作区:
    git status --porcelain
    
    有未提交改动时明确警告,但不阻止,因为这些改动可能正是本次待发布内容。后续只修改约定的版本锚点,不覆盖其他改动。
  5. 确认 beta 没有遗漏远端提交:
    git log beta..origin/beta --oneline
    git log beta..origin/main --oneline
    
    任一命令有输出都停止:本地 beta 落后于远端,必须先同步或处理分歧。
  6. origin/mainSkillsLogger.Version 读取当前稳定版本 {OLD_VER},不要依赖可能过期的本地 main
    git show origin/main:SkillsForUnity/Editor/Skills/SkillsLogger.cs
    
  7. 查询 GitHub 当前最新稳定 Release:
    gh api repos/Besty0728/Unity-Skills/releases/latest \
      --jq '{tag_name,html_url,draft,prerelease}'
    
    • tag_name 必须严格为 vMAJOR.MINOR.PATCH
    • 必须是非 draft、非 prerelease。
    • 正常情况下其版本应等于 {OLD_VER};若不一致,停止并报告“main 当前版本与 latest Release 已错位”,不要猜测基准版本。
  8. 验证当前工作树内的所有项目版本锚点仍等于 {OLD_VER}
    python3 .github/scripts/check_project_version.py . --expected "{OLD_VER}"
    
    不一致时先修复已有漂移,不得继续批量升版。
  9. 用数值元组比较语义版本。{NEW_VER} 必须严格高于 {OLD_VER},也必须严格高于 GitHub latest Release 的版本;禁止使用字符串字典序比较。
  10. 判定本次更迭级别 {BUMP_LEVEL} 并记录下来,步骤 4 与步骤 5 都依赖它:
    • {OLD_VER}{NEW_VER} 各自拆成 MAJOR.MINOR.PATCH 三段整数后逐段比较,不做字符串比较。
    • MAJOR 段不同 → majorMAJOR 相同而 MINOR 段不同 → minor;只有 PATCH 段不同 → patch
    • 例:2.9.1 → 3.0.0major2.6.3 → 2.7.0minor2.3.1 → 2.3.2patch
    • 只有 major / minor 会让 .github/SECURITY.md 进入本次改动范围(见步骤 4)。

Read the full file on GitHub · 224 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 224 lines · 0 tokens per session scan A fb2fb28e615c

Subscribe to this mod's changes

updateversion is a command published in the GitHub repository Besty0728/Unity-Skills (1,695 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 3,209 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.