Finish the 0.3.0 renames: bunInstall, testForked, bunBundleFormat, env hooks - #22
Merged
arcaputo3 merged 1 commit intoAug 27, 2026
Merged
Conversation
…v hooks The TypeScript install task is canonically bunInstall; Mill's inherited npmInstall delegates to it and stays usable. All internal call sites use the canonical name, so install artifacts live in bunInstall.dest. Both module kinds share one test entrypoint name: testForked. The TypeScript test command `test` is a deprecated alias, and the Scala.js bunTest — which duplicated the inherited testForked exactly, since the overridden jsEnvConfig and testLinkTask already put every test run on Bun — is deprecated in its favor. TypeScript bunBundleFormat is Option[String], matching Scala.js. The type disagreement was the one rename no alias could bridge; 0.3.0 takes the one-time break, and None now lets `bun build` infer the format. BunWorkersModule.workerBundleFormat follows it directly. Environment hooks share one vocabulary: bunToolEnv (install, lock, build subprocesses) is defined once on BunToolchainModule and used by every runBun call site — Scala.js, TypeScript, workspace, publish, and workers modules previously mixed bunEnv() and bunToolEnv() — and the TypeScript bunRuntimeEnv is public instead of protected. Integration tests exercise the canonical names throughout, with explicit alias regression coverage: npmInstall must resolve to bunInstall.dest, and the deprecated test / bunTest commands must keep working until their removal at 1.0. MIGRATING-0.3.md documents the new rows and the bunBundleFormat break with a before/after example. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
arcaputo3
changed the base branch from
agent/bun-unmanaged-deps
to
agent/idiomatic-scalajs-mill-workflows
August 27, 2026 00:57
arcaputo3
merged commit Aug 27, 2026
2cd092b
into
agent/idiomatic-scalajs-mill-workflows
8 checks passed
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.
Stacked on #21 (
agent/bun-unmanaged-deps). Completes the 0.3.0 rename decision: one migration, not two.What changes
bunInstallis the canonical TypeScript install task. Mill's inheritednpmInstalldelegatesto it and keeps working (upstream internals resolve it, and so can users). All internal call
sites use the canonical name, so install artifacts move to
out/<module>/bunInstall.dest.Both module kinds share one test entrypoint:
testForked.testcommand is a deprecated alias of the newtestForked.bunTestis deprecated in favor of the inheritedtestForked— review showed itduplicated it exactly: the overridden
jsEnvConfigandtestLinkTaskalready put every testrun on Bun, so
bunTestadded nothing but a second name.bunBundleFormatisT[Option[String]]on TypeScript, matching Scala.js. This is the onerename with no alias path — a type change can't be deprecated gracefully — so it lands as the
documented hard break. Default preserves behavior (
Some("esm"/"cjs")fromenableEsm);Nonelets
bun buildinfer.workerBundleFormatfollows it directly.Environment hooks share one vocabulary.
bunToolEnv(install / lock / build subprocesses)is defined once on
BunToolchainModuleand used by everyrunBuncall site — previously theScala.js, workspace, publish, and workers modules called
bunEnv()directly while TypeScriptused a
protected bunToolEnv, so overriding the toolchain environment behaved differently permodule kind. TypeScript's
bunRuntimeEnvis now public. Scala.js keepsbunJsEnv/bunJsEnvArgs/bunTestJsEnvunchanged — that's released API for the Scala.js test JS env.Compatibility story
npmInstall(TS)bunInstalltest(TS tests)testForked@deprecatedaliasbunTest(Scala.js tests)testForked(inherited)@deprecatedaliasbunBundleFormat: T[String](TS)T[Option[String]]MIGRATING-0.3.md gains the new table rows, the
bunBundleFormatbefore/after example, and theenv-vocabulary note. CHANGELOG updated under [Unreleased].
Tests
Integration tests exercise canonical names throughout, plus explicit alias regression coverage:
app.npmInstallmust resolve tobunInstall.dest, and the deprecatedtest/bunTestcommands must keep evaluating until their removal at 1.0. The
typescript-bundlefixture'sbunBundleFormatoverride was migrated exactly as the doc shows. Full suites green.