From 18a3399947d67c0ade6aa52387ddc58117d5c5b3 Mon Sep 17 00:00:00 2001 From: Theo Ephraim Date: Wed, 29 Apr 2026 23:34:26 -0700 Subject: [PATCH 1/3] Skip default values during changeset migration Don't write empty arrays (fixed, linked, ignore) or values matching bumpy defaults (baseBranch: main, access: public, etc.) into the migrated config file. --- packages/bumpy/src/commands/init.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/packages/bumpy/src/commands/init.ts b/packages/bumpy/src/commands/init.ts index 80a066d..c2774f8 100644 --- a/packages/bumpy/src/commands/init.ts +++ b/packages/bumpy/src/commands/init.ts @@ -171,9 +171,14 @@ function migrateChangesetConfig(csConfig: Record): Record Date: Thu, 30 Apr 2026 11:37:35 -0700 Subject: [PATCH 2/3] Add bump file for migration fix --- .bumpy/fix-migration-defaults.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .bumpy/fix-migration-defaults.md diff --git a/.bumpy/fix-migration-defaults.md b/.bumpy/fix-migration-defaults.md new file mode 100644 index 0000000..b25ff23 --- /dev/null +++ b/.bumpy/fix-migration-defaults.md @@ -0,0 +1,5 @@ +--- +'@varlock/bumpy': patch +--- + +Skip default values (empty arrays, baseBranch: main, etc.) during changeset migration From ebc1384e38600bbc3dc9590f1579ef829d480fd8 Mon Sep 17 00:00:00 2001 From: Theo Ephraim Date: Thu, 30 Apr 2026 11:44:55 -0700 Subject: [PATCH 3/3] Change packages output to JSON array for exact matching CSV format caused false positives (e.g. "mylib" matching "mylib-plugin"). JSON array enables exact matching via fromJSON() + contains() in GH Actions. --- docs/cli.md | 10 +++++----- docs/github-actions.md | 12 ++++++------ packages/bumpy/src/commands/ci.ts | 2 +- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/docs/cli.md b/docs/cli.md index 07bb080..a7740c3 100644 --- a/docs/cli.md +++ b/docs/cli.md @@ -207,11 +207,11 @@ bumpy ci plan **GitHub Actions outputs** (set via `$GITHUB_OUTPUT`): -| Output | Description | -| ---------- | ------------------------------------- | -| `mode` | `version-pr`, `publish`, or `nothing` | -| `packages` | Comma-separated package names | -| `json` | Full JSON output (for `fromJSON()`) | +| Output | Description | +| ---------- | ------------------------------------------------------------- | +| `mode` | `version-pr`, `publish`, or `nothing` | +| `packages` | JSON array of package names (for `fromJSON()` + `contains()`) | +| `json` | Full JSON output (for `fromJSON()`) | When `ci plan` runs before `ci release` in the same workflow, the plan is cached so `ci release` can skip duplicate registry lookups. The cache is validated against the workspace (package names and versions must match) and deleted after use. diff --git a/docs/github-actions.md b/docs/github-actions.md index 25123bf..cd23231 100644 --- a/docs/github-actions.md +++ b/docs/github-actions.md @@ -120,11 +120,11 @@ Publishing often requires expensive build steps that aren't needed when just upd `ci plan` outputs JSON to stdout, sets GitHub Actions step outputs, and caches the result so that `ci release` can skip duplicate registry lookups in the same workflow run. -| Output | Description | -| ---------- | ------------------------------------- | -| `mode` | `version-pr`, `publish`, or `nothing` | -| `packages` | Comma-separated package names | -| `json` | Full JSON output (for `fromJSON()`) | +| Output | Description | +| ---------- | ------------------------------------------------------------- | +| `mode` | `version-pr`, `publish`, or `nothing` | +| `packages` | JSON array of package names (for `fromJSON()` + `contains()`) | +| `json` | Full JSON output (for `fromJSON()`) | ### Basic: skip builds unless publishing @@ -170,7 +170,7 @@ jobs: GH_TOKEN: ${{ github.token }} # Build only specific packages that are being released -- if: contains(steps.plan.outputs.packages, 'my-expensive-package') +- if: contains(fromJSON(steps.plan.outputs.packages), 'my-expensive-package') run: bun run build --filter=my-expensive-package ``` diff --git a/packages/bumpy/src/commands/ci.ts b/packages/bumpy/src/commands/ci.ts index 3931504..96c0b04 100644 --- a/packages/bumpy/src/commands/ci.ts +++ b/packages/bumpy/src/commands/ci.ts @@ -309,7 +309,7 @@ export async function ciPlanCommand(rootDir: string): Promise { // Set GitHub Actions outputs writeGitHubOutput('mode', output.mode); - writeGitHubOutput('packages', output.packageNames.join(',')); + writeGitHubOutput('packages', JSON.stringify(output.packageNames)); writeGitHubOutput('json', JSON.stringify(output)); }