From 7105ff5ff7e94cfefe9123f1ddc6b7408844a18a Mon Sep 17 00:00:00 2001 From: Minsu Lee Date: Wed, 14 Oct 2026 16:46:19 +0900 Subject: [PATCH] fix(cli): depend on @pleaseai/ast-grep-config with a caret range `workspace:*` packs as the exact version bun.lock records, so 0.1.0 shipped depending on `@pleaseai/ast-grep-config@0.0.1`, which was never published, and cannot be installed. bun.lock is now synced on the release PR (#51); `workspace:^` also lets ast-grep-config patch releases reach the CLI without a new CLI release. A pack now writes `^0.1.0`. --- .github/workflows/release-please.yml | 2 +- bun.lock | 2 +- packages/cli/package.json | 2 +- scripts/sync-bun-lock.ts | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release-please.yml b/.github/workflows/release-please.yml index 41f7d4b..b943fe3 100644 --- a/.github/workflows/release-please.yml +++ b/.github/workflows/release-please.yml @@ -45,7 +45,7 @@ jobs: manifest-file: .release-please-manifest.json # release-please bumps package.json but not bun.lock - # (googleapis/release-please#2689), and `bun pm pack` resolves `workspace:*` + # (googleapis/release-please#2689), and `bun pm pack` resolves `workspace:` # dependencies from the versions bun.lock recorded. Commit the synced # lockfile to the release PR so the release ships it. sync-bun-lock: diff --git a/bun.lock b/bun.lock index 9b7665c..1db4e34 100644 --- a/bun.lock +++ b/bun.lock @@ -66,7 +66,7 @@ }, "dependencies": { "@clack/prompts": "^1.8.1", - "@pleaseai/ast-grep-config": "workspace:*", + "@pleaseai/ast-grep-config": "workspace:^", }, "devDependencies": { "@ast-grep/cli": "0.45.3", diff --git a/packages/cli/package.json b/packages/cli/package.json index 343966e..fe022e6 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -54,7 +54,7 @@ }, "dependencies": { "@clack/prompts": "^1.8.1", - "@pleaseai/ast-grep-config": "workspace:*" + "@pleaseai/ast-grep-config": "workspace:^" }, "devDependencies": { "@ast-grep/cli": "0.45.3", diff --git a/scripts/sync-bun-lock.ts b/scripts/sync-bun-lock.ts index 365ef41..6218fdd 100644 --- a/scripts/sync-bun-lock.ts +++ b/scripts/sync-bun-lock.ts @@ -1,7 +1,7 @@ /** * Syncs each workspace's `version` in bun.lock with its package.json. * - * `bun pm pack` resolves `workspace:*` dependencies from the version bun.lock + * `bun pm pack` resolves `workspace:` dependencies from the version bun.lock * recorded, and `bun install` does not refresh it after a version bump. * release-please bumps package.json only (googleapis/release-please#2689), so * the release workflow runs this on the release PR branch. Without it the