release-deploy

Release and deploy via GitHub tags and GitHub Actions (not every commit). Creates production releases from main and beta releases from staging using the GitHub CLI. Use when the user asks to release,

SKILL.md

GitHub

Release & Deploy (GitHub Tags)

Leading words: commits ≠ deploys; branch → channel; tag triggers ship; changelog is truth; interview once; never guess channel.

Core model

  • Commits ≠ deploys. Only a git tag + GitHub Release triggers deployment (via GitHub Actions or project-specific release jobs).
  • Branch → channel
    • main → production release
    • staging → beta release
  • Tags
    • Production: vMAJOR.MINOR.PATCH (e.g. v1.4.0)
    • Beta: vMAJOR.MINOR.PATCH-beta.N (e.g. v1.4.0-beta.1)
  • Release notes come from the project's maintained CHANGELOG.md (do not invent a changelog). See references/versioning.md.

Before every release

  1. Load project config
  2. Confirm channel with the user: beta (staging) or production (main). Never guess.
  3. Verify git state (PowerShell-safe; run as separate commands):
    • Correct branch checked out (staging or main)
    • Working tree clean (or user explicitly accepts dirty)
    • Branch is up to date with its remote
    • HEAD is the commit they intend to ship
  4. Determine next version from existing tags + user intent. Follow references/versioning.md.
  5. Extract notes from CHANGELOG.md for that version (or [Unreleased] if they are cutting that section into a version). If changelog is missing/ambiguous → stop and ask.

Release workflow

Follow references/gh-release.md. Summary:

  1. Ensure on the correct branch at the intended commit.
  2. Create annotated tag locally (optional if gh release create will create it).
  3. gh release create with tag, title, notes from changelog, and --target set to the branch (or SHA).
  4. Watch the project's release/deploy workflow (from project config) until green or report failure.
  5. Summarize: tag, release URL, channel, deploy target/URL from project config.

Hard rules

  • Never tag production from staging, or beta from main, unless the project config explicitly documents a different branch map and the user confirms.
  • Never force-push tags or delete remote tags without explicit user request.
  • Never skip the interview on a first release in a repo.
  • Never fabricate changelog entries; only use CHANGELOG.md (or ask the user to update it first).
  • Prefer gh over raw API calls. Prefer project config over inventing deploy steps.

Platform-specific behavior

After the interview, project config names the stack. Read the matching reference only when needed:

Additional resources