feat(cli): discover Bash for Windows runners

Use Pi-style Bash discovery and launch behavior, exercise the packaged CLI shell, and wait for pending ZIP metadata reads before closing cancelled downloads.
This commit is contained in:
yiling
2026-11-18 10:57:04 +08:00
parent 776f6962b6
commit fd4dc211f8
18 changed files with 453 additions and 63 deletions
+2
View File
@@ -81,6 +81,7 @@ export async function assembleCliRelease(outdir: string, targets = cliTargetName
export async function buildCliRelease(outdir: string, targets = cliTargetNames) {
validateCliVersion(version)
if (cliVersion !== version) throw new Error('Root and CLI package versions must match')
const notices = await readFile(join(repoRoot, 'apps/cli/THIRD-PARTY-NOTICES.txt'), 'utf8')
await mkdir(outdir, { recursive: true })
const staging = await mkdtemp(join(outdir, '.build-'))
try {
@@ -91,6 +92,7 @@ export async function buildCliRelease(outdir: string, targets = cliTargetNames)
entrypoints: [join(repoRoot, 'apps/cli/src/index.ts')],
target: 'bun',
minify: true,
banner: '/*\n' + notices + '*/',
plugins: [srtBundlePlugin(...target.split('-'))],
compile: {
target: cliTargets[target],