Changeset Creation Skill
Create changeset files for projects using @changesets/cli.
Context
- •Existing changesets: !
ls .changeset/*.md 2>/dev/null | head -5 - •Workspace packages: !
for dir in packages/* plugins/*; do [ -f "$dir/package.json" ] && jq -r '.name' "$dir/package.json"; done 2>/dev/null | sort
Instructions
Step 1: Detect Packages
- •This is a monorepo with workspaces in
packages/*andplugins/* - •Find all
package.jsonfiles in workspace directories and extract names - •IMPORTANT: Never use the root package name ("root") - only use actual workspace package names
- •Common packages for app-wide changes:
app,backend
Step 2: Gather Information
Use AskUserQuestion tool to ask:
- •Package Selection (if multiple packages): Which packages should be included? Use multiSelect: true to allow selecting multiple packages.
- •Version Bump Type: For each selected package - patch, minor, or major?
- •Summary: Brief description of changes for the changelog
Step 3: Generate Unique Filename
Generate human-readable ID: {adjective}-{noun}-{verb}
Word lists:
Adjectives: ancient, bright, calm, deep, eager, fair, gentle, happy, icy, jolly, kind, light, mild, noble, odd, plain, quick, rare, soft, tall, unique, vast, warm, young, zesty, bold, clean, dark, empty, fresh, grand, humble, ideal, keen, loud, merry, neat, open, proud, quiet, rich, sharp, sweet, tidy, vivid, wise, witty, brave, clever
Nouns: apple, beach, cloud, eagle, flame, grape, heart, island, jewel, kite, lemon, maple, night, ocean, pearl, river, stone, tiger, violet, water, bamboo, canyon, desert, ember, forest, garden, harbor, jungle, kingdom, lagoon, meadow, nebula, oasis, planet, rainbow, sunset, thunder, valley, willow, bridge, castle, dolphin, falcon, glacier, horizon, lantern, mirror, orchard, phoenix
Verbs: bloom, climb, dance, explore, float, glide, hover, ignite, jump, kindle, launch, melt, nestle, orbit, ripple, shine, travel, unfold, venture, wander, adapt, blend, create, drift, emerge, flow, grow, heal, inspire, journey, learn, mingle, observe, persist, reflect, soar, thrive, twist, unite, whisper
Pick one word randomly from each list. Check if .changeset/{id}.md exists; if so, regenerate.
Step 4: Write Changeset File
Create .changeset/{id}.md:
--- "package-name": patch --- Summary description here.
Rules:
- •Package names MUST be quoted
- •Only use actual workspace package names (e.g.,
app,backend,@giantswarm/backstage-plugin-gs) - •NEVER use the root package name ("root") - it will break
yarn changeset version - •End file with newline
- •Create
.changeset/directory if missing
Step 5: Confirm
Display:
- •Path to created changeset
- •File contents
- •Remind user to commit the file