Changesets

From TerminalSkills/skills · View interactive version

Changesets is an AI agent skill from the GitHub repository TerminalSkills/skills. Changesets manages versions and changelogs for JavaScript/TypeScript packages and monorepos with small markdown files committed alongside code changes. Use when automating semantic versioning, generating changelogs from PRs, coordinating multi-package releases, or publishing to npm. Trigger words: c

How to use this skill

Skill file

Changesets

Overview

Changesets is a versioning and changelog management tool for JavaScript/TypeScript monorepos. Developers add changeset files describing their changes, then CI consumes them to bump package versions, generate changelogs, and publish to npm with coordinated releases across interdependent packages.

Instructions

Examples

Example 1: Set up automated releases for a monorepo

User request: "Configure Changesets for automated versioning and publishing in my Turborepo monorepo"

npm install -D @changesets/cli @changesets/changelog-github
npx changeset init
# .github/workflows/release.yml
name: Release
on:
  push:
    branches: [main]
permissions:
  contents: write
  pull-requests: write
  id-token: write
jobs:
  release:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-node@v4
        with: { node-version: 24 }
      - run: npm ci
      - uses: changesets/action@v2
        with:
          publish-script: npm run release   # "release": "turbo build && changeset publish"

Result: every merge to main with pending changesets updates a "Version Packages" PR; merging that PR publishes the packages to npm and tags them.

Example 2: Coordinate a breaking change across packages

User request: "Release a major version of @acme/core and make sure dependents are updated"

$ npx changeset -m "Rename client options" --major @acme/core
$ npx changeset version
$ grep version packages/*/package.json
packages/cli/package.json:{"name":"@acme/cli","version":"1.0.1","dependencies":{"@acme/core":"^2.0.0"}}
packages/core/package.json:{"name":"@acme/core","version":"2.0.0"}

Result: core goes to 2.0.0, @acme/cli is patch-bumped to 1.0.1 with its dependency range moved to ^2.0.0, and both changelogs list the change. If @acme/cli should also change its public API, add its own changeset with the right bump type.

Guidelines

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.