Configure semantic-release for path-scoped CLI releases - #10
Merged
Conversation
… policy
Two related changes to the release automation:
1. Path-scope CLI releases. semantic-release now runs from packages/cli/
with extends: semantic-release-monorepo, which filters analyzed commits
to those that touched packages/cli/**. Web, docs, and roadmap changes
no longer mint CLI versions. CHANGELOG.md still lives at the repo root
via @semantic-release/changelog's changelogFile: ../../CHANGELOG.md.
2. Reshape the 0.x bump policy. In alpha (0.x) we want the minor to mark
completed milestones, not every in-flight feat:. New rules:
- milestone: -> minor (closes a roadmap milestone)
- feat: -> patch (intermediate progress)
- fix/perf/refactor/security/build/revert -> patch
- BREAKING CHANGE / ! -> minor (0.x graduation guard, unchanged)
- docs/test/ci/chore -> no release
Post-1.0 the standard feat -> minor mapping returns; for now milestone:
is the only way to bump the minor.
- commitlint.config.cjs: add `milestone` to type-enum
- packages/cli/.releaserc.json: extends semantic-release-monorepo;
updated releaseRules; release-notes-generator gets a Milestones section
- .github/workflows/release.yml: run semantic-release from packages/cli;
capture before/after version to detect actual publish; tag format
cli-vX.Y.Z used for the publish job's checkout ref
- RELEASING.md: document the new 0.x bump table, milestone vs feat
distinction, and path-scoped behavior
- package.json: pin semantic-release-monorepo ^8.0.2
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Configures semantic-release to run from
packages/cli/with monorepo support, enabling path-scoped versioning so that only commits touching CLI code trigger version bumps. Also introduces a newmilestone:commit type for graduating roadmap milestones and adjusts the 0.x bump policy sofeat:commits are patches (not minors) until a milestone is completed.Key Changes
semantic-release-monorepoplugin to.releaserc.jsonand updated release workflow to run frompackages/cli/directory, filtering commits to CLI-only changesmilestone:prefix (minor bump in 0.x) for commits that complete a roadmap milestone; updatedcommitlint.config.cjsto allow itfeat:from minor → patch in 0.x, so incremental feature work doesn't bump the minor; onlymilestone:bumps minor when a milestone is completedcli-vX.Y.Zformat (instead ofvX.Y.Z) to distinguish CLI releases in a monorepo context../../CHANGELOG.md) instead of package rootrelease.ymlto detect version changes by comparing before/after, and explicitly setnew_release_published=falsewhen no version bump occursDocumentation Updates
RELEASING.mdwith:feat:as patchsemantic-release-monorepofilters commitsmilestone:and reordered entries to reflect new policyImplementation Details
semantic-release-monorepoautomatically filters commits to those touchingpackages/cli/**, so docs-only or roadmap-only changes don't trigger CLI releases{ "breaking": true, "release": "minor" }rule in.releaserc.jsonpkgRootfrom npm plugin config since semantic-release now runs from the correct directoryhttps://claude.ai/code/session_01JD2ZC6w3rWKodHFv4333Fu