Skip to content

Fix modern Bun lockfile cleanup in app templates#7436

Open
afurm wants to merge 1 commit intoShopify:mainfrom
afurm:af/fix-bun-lockfile-cleanup
Open

Fix modern Bun lockfile cleanup in app templates#7436
afurm wants to merge 1 commit intoShopify:mainfrom
afurm:af/fix-bun-lockfile-cleanup

Conversation

@afurm
Copy link
Copy Markdown

@afurm afurm commented Apr 30, 2026

WHY are these changes introduced?

No linked issue.

Shopify CLI already detects Bun projects from both bun.lockb and modern bun.lock, but app template cleanup only treated bun.lockb as Bun's lockfile. This could leave stale bun.lock files or .gitignore entries behind when initializing non-Bun app projects.

WHAT is this pull request doing?

  • Adds modern bun.lock to the shared lockfile list.
  • Adds lockfilesForPackageManager() so Bun keeps both valid Bun lockfile names.
  • Updates app template cleanup to remove unused modern Bun lockfiles for non-Bun projects.
  • Adds focused regression coverage and a patch changeset.

How to test your changes?

pnpm test packages/app/src/cli/services/init/template/cleanup.test.ts packages/cli-kit/src/public/node/node-package-manager.test.ts
pnpm --filter @shopify/cli-kit type-check
pnpm --filter @shopify/app type-check
pnpm --filter @shopify/cli-kit lint
pnpm --filter @shopify/app lint

Checklist

  • I've considered possible cross-platform impacts (Mac, Linux, Windows)
  • I've considered possible documentation changes
  • I've considered analytics changes to measure impact
  • The change is user-facing — I've identified the correct bump type (patch for bug fixes · minor for new features · major for breaking changes) and added a changeset with pnpm changeset add

@afurm afurm requested review from a team as code owners April 30, 2026 14:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant