stim 1.17.0 → 1.17.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/dist/{android--GorydsK.mjs → android-B6rDWrTm.mjs} +15 -15
  2. package/dist/{budget-DM984mnd.mjs → budget-CUDz870h.mjs} +30 -9
  3. package/dist/{build-plan-CmQCoyT-.mjs → build-plan-BJSXzsCL.mjs} +14 -14
  4. package/dist/{idle-B2m-Ovod.mjs → build-progress-D0WkjCPd.mjs} +56 -183
  5. package/dist/{cli-Daxug5-K.mjs → cli-BLQqDGlX.mjs} +13 -13
  6. package/dist/cli.mjs +1 -1
  7. package/dist/{machines-C2XiNwh9.mjs → client-CxNotugx.mjs} +314 -303
  8. package/dist/{deps-DNWaQs4V.mjs → deps-CVxlsRFn.mjs} +1 -1
  9. package/dist/{device-capacity-D0GWHnTM.mjs → device-capacity-ZC4XSZ4R.mjs} +2 -2
  10. package/dist/device-host-worker.mjs +3 -3
  11. package/dist/{device-ios-Bc7vbGwl.mjs → device-ios-C2Um-XUR.mjs} +1 -1
  12. package/dist/{doctor-Cnk9d7Hm.mjs → doctor-BF_435OC.mjs} +14 -13
  13. package/dist/{gc-DxCL2A46.mjs → gc-BsWKa_-d.mjs} +9 -8
  14. package/dist/{gradle-D7-L2Th3.mjs → gradle-bsBRy6i9.mjs} +1 -1
  15. package/dist/{guide-DjrTQGik.mjs → guide-DC3n6-NH.mjs} +134 -110
  16. package/dist/{hosted-android-DwLS4Mse.mjs → hosted-android-DgU31wY3.mjs} +3 -3
  17. package/dist/{hosted-client-wk1W_CNW.mjs → hosted-client-CdSoH-G6.mjs} +4 -4
  18. package/dist/{hosted-ios-aMo7Cljf.mjs → hosted-ios-BTaVj4Jb.mjs} +1 -1
  19. package/dist/{hosted-logs-DqYmWtXc.mjs → hosted-logs-SxfBvSvc.mjs} +2 -2
  20. package/dist/{hosted-macos-dlHXEeF5.mjs → hosted-macos-CT9E3meL.mjs} +2 -2
  21. package/dist/{hosted-native-C9xJ9rpA.mjs → hosted-native-CZLOrMrN.mjs} +3 -3
  22. package/dist/idle-BXG__1BA.mjs +176 -0
  23. package/dist/{idle-shutdown-_3oOV1V_.mjs → idle-shutdown-IGyNV8Cr.mjs} +1 -1
  24. package/dist/{ios-DE6duQoz.mjs → ios-C7JuT1bI.mjs} +18 -18
  25. package/dist/{logs-DUoKlDoS.mjs → logs-DNxKcok9.mjs} +3 -3
  26. package/dist/{macos-32po3kUq.mjs → macos-BEs8cwKx.mjs} +66 -25
  27. package/dist/maintenance-run.mjs +2 -2
  28. package/dist/{metro-gateway-DmslUM30.mjs → metro-gateway-CHqK0p-a.mjs} +1 -1
  29. package/dist/{native-runtime-DhJI3IVQ.mjs → native-runtime-YhaSxP4v.mjs} +1 -1
  30. package/dist/offload-worker.mjs +5 -5
  31. package/dist/{preview-CxPRIEht.mjs → preview-C_JjkEy4.mjs} +1 -1
  32. package/dist/{reload-qZei6iWn.mjs → reload-byOjE3P4.mjs} +2 -2
  33. package/dist/settings.schema.json +84 -66
  34. package/dist/{start-BopZcr4n.mjs → start-BEP-XmEA.mjs} +1 -1
  35. package/dist/{start-uee1wWjY.mjs → start-BHIersSm.mjs} +1 -1
  36. package/dist/{status-dXX2JX1C.mjs → status-CqeWbIWW.mjs} +8 -8
  37. package/dist/{stop-BjizrQwv.mjs → stop-Cj01je8D.mjs} +3 -3
  38. package/dist/{stop-Cr1d8DSE.mjs → stop-D03prQnW.mjs} +1 -1
  39. package/dist/{stop-BCwvvs7F.mjs → stop-DOxwkH4j.mjs} +1 -1
  40. package/dist/supervisor-run.mjs +4 -4
  41. package/dist/{support-BJPgYCu-.mjs → support-BE-tbOP9.mjs} +4 -4
  42. package/dist/{support-F9-sr0Oi.mjs → support-WvD__tSV.mjs} +2 -2
  43. package/dist/{toolchain-CNIBTIOv.mjs → toolchain-CdrxgUeA.mjs} +1 -1
  44. package/dist/{web-exQtGkoc.mjs → web-DddUdJzr.mjs} +2 -2
  45. package/dist/{worktree-ZpZR3S1k.mjs → worktree-AK_m-d_m.mjs} +6 -6
  46. package/dist/{worktree-Dc98cE6_.mjs → worktree-CsAjSmEo.mjs} +1 -1
  47. package/package.json +5 -5
@@ -1,7 +1,7 @@
1
1
  import { t as getExecutor } from "./exec-CaErVv7t.mjs";
2
2
  import { n as stripAnsi, r as waitForChild, t as createLineReader } from "./process-output-Fpl8PYi8.mjs";
3
3
  import { a as spawnDeclared } from "./spawn-claims-D0XfSe8u.mjs";
4
- import { S as bundlerPin, u as HEARTBEAT_INTERVAL_MS, y as startBuildHeartbeat } from "./toolchain-CNIBTIOv.mjs";
4
+ import { S as bundlerPin, u as HEARTBEAT_INTERVAL_MS, y as startBuildHeartbeat } from "./toolchain-CdrxgUeA.mjs";
5
5
  import { existsSync, readFileSync } from "node:fs";
6
6
  import { delimiter, dirname, join, relative, resolve, sep } from "node:path";
7
7
  import { homedir } from "node:os";
@@ -7,9 +7,9 @@ import { n as withIdleWorkspace, o as canonicalPath } from "./in-use-CvGOUn-x.mj
7
7
  import { O as listAdbDevices } from "./android-B_YNZy61.mjs";
8
8
  import { _ as parseRuntimeVersion, c as iosRuntimeMatches, u as listAllIosSims } from "./ios-DSfnPfse.mjs";
9
9
  import { n as workspaceProcessLockError, t as withWorkspaceProcessLock } from "./workspace-process-lock-2mNzOlaB.mjs";
10
- import { S as recordCapacityWait, x as recordCapacityRefusal } from "./idle-B2m-Ovod.mjs";
10
+ import { h as recordCapacityWait, m as recordCapacityRefusal } from "./build-progress-D0WkjCPd.mjs";
11
11
  import { r as createNdjsonWriter } from "./ndjson-PclOIwVY.mjs";
12
- import { n as dueIdleDevices, r as shutDownIdleDevices } from "./idle-shutdown-_3oOV1V_.mjs";
12
+ import { n as dueIdleDevices, r as shutDownIdleDevices } from "./idle-shutdown-IGyNV8Cr.mjs";
13
13
  import { realpathSync } from "node:fs";
14
14
  import { basename, join } from "node:path";
15
15
  import { LOG_ROTATE_BYTES, workspaceId } from "@stim-cli/core";
@@ -10,10 +10,10 @@ import { a as requiredMacosRecord, r as macosProcess } from "./state-DyaNTgfR.mj
10
10
  import { r as createNdjsonWriter } from "./ndjson-PclOIwVY.mjs";
11
11
  import { n as parseLogStreamLine } from "./ios-Cr1h5gnO.mjs";
12
12
  import { n as parseLogcatLine, r as parsePidof, t as androidClockOffset } from "./android-DE4v59Mb.mjs";
13
- import { i as countLiveOwnedDevices } from "./device-capacity-D0GWHnTM.mjs";
13
+ import { i as countLiveOwnedDevices } from "./device-capacity-ZC4XSZ4R.mjs";
14
14
  import { C as reverseMetroPorts, _ as installIosApp, b as launchAndroidReleaseApp, h as installAndroidApp, s as androidAppProcess, v as iosAppProcess, w as writeDebugHttpHost, x as launchIosApp, y as launchAndroidApp } from "./app-install-VPkI5WEg.mjs";
15
- import { h as findAapt } from "./support-F9-sr0Oi.mjs";
16
- import { n as stopMacosAppHeld } from "./stop-Cr1d8DSE.mjs";
15
+ import { h as findAapt } from "./support-WvD__tSV.mjs";
16
+ import { n as stopMacosAppHeld } from "./stop-D03prQnW.mjs";
17
17
  import { t as spawnEntry } from "./spawn-entry-jw19m8Nl.mjs";
18
18
  import { createHash, randomUUID } from "node:crypto";
19
19
  import { chmodSync, closeSync, copyFileSync, createReadStream, existsSync, lstatSync, mkdirSync, openSync, readFileSync, readdirSync, realpathSync, renameSync, rmSync, statfsSync, symlinkSync, writeFileSync } from "node:fs";
@@ -8,7 +8,7 @@ import { ct as dropParked, ft as parkedMaxSetting, ht as selectParked, pt as rea
8
8
  import { A as hostMemoryPressureAdvice, C as resolveIosCreation, O as configuredIosSimulatorViewer, S as resetIosPrivacy, _ as parseRuntimeVersion, b as renameIosSim, f as listIosDeviceTypes, h as ownedSimName, i as createOwnedIosSim, j as readHostMemoryPressure, l as iosSimulatorFailureAdvice, n as bootIosSim, p as listIosRuntimes, u as listAllIosSims, w as resolveOwnedIosSim, x as resetIosKeychain } from "./ios-DSfnPfse.mjs";
9
9
  import { v as teardownParkedIosSim } from "./ownership-BMLqyBgJ.mjs";
10
10
  import { t as withWorkspaceProcessLock } from "./workspace-process-lock-2mNzOlaB.mjs";
11
- import { a as deviceTypeMismatch, c as runtimeMismatch, n as DeviceAdmissionRefusal, p as withDeviceBootAdmission } from "./device-capacity-D0GWHnTM.mjs";
11
+ import { a as deviceTypeMismatch, c as runtimeMismatch, n as DeviceAdmissionRefusal, p as withDeviceBootAdmission } from "./device-capacity-ZC4XSZ4R.mjs";
12
12
  import chalk from "chalk";
13
13
  //#region src/engine/device-ios.ts
14
14
  function startIosBoot(udid, configure, label, out, simulatorApp, root, deviceSlotWait) {
@@ -4,17 +4,17 @@ import { d as quotedPath, f as refuseNoProject, l as phaseLine, u as plural } fr
4
4
  import { B as settingsLayers, Ct as filesystemDevice, Et as temporaryRoot, H as unknownSettingKeys, I as settingOrigin, M as remoteIosSetting, O as projectOptimizations, P as resolveSettings, R as settingShapeErrors, U as webSettings, Y as compilerCacheFallbackMessage, Z as resolveOptimizations, dt as listWorktrees, ft as locallyKnownUpstream, gt as repoRoot, i as SETTING_SHAPE_REMEDY, it as gitCommonDir, j as remoteAndroidSetting, n as PATH_SETTINGS, nt as dirtyFingerprintFiles, r as SETTINGS_WITH_RESOLVE_TIME_FALLBACK, v as iosSimSlimProfileSetting, vt as resolveSourceCheckout, wt as makeTemporaryDirectory, y as mergeSettingsLayers } from "./settings-Cfd-0r2d.mjs";
5
5
  import { l as isPackageResolvable, n as appProjectProblem, r as detectIsExpo, s as findProjectRoot$1 } from "./project-D47Rh0ly.mjs";
6
6
  import { _ as workspaceDerivedData, d as sharedBuildCache } from "./workspace-state-DqcCbpE7.mjs";
7
- import { B as inspectWatchmanMemory, i as inspectBudget, n as budgetLine } from "./budget-DM984mnd.mjs";
7
+ import { V as inspectWatchmanMemory, i as inspectBudget, n as budgetLine } from "./budget-CUDz870h.mjs";
8
8
  import { C as diffFingerprintSources, D as fingerprintProject, h as listBuildLocks } from "./device-lease-DpoS36_u.mjs";
9
9
  import { n as listBuildSlots } from "./build-slots-41v_d2x9.mjs";
10
10
  import { D as hostSystemImageArch, ft as parkedMaxSetting, o as androidHome, ot as POOL_SETTING_REMEDY } from "./android-B_YNZy61.mjs";
11
11
  import { A as hostMemoryPressureAdvice, c as iosRuntimeMatches, j as readHostMemoryPressure, p as listIosRuntimes, y as pickDefaultIosCreation } from "./ios-DSfnPfse.mjs";
12
- import { C as podInstallCommand, D as projectCmakeLauncher, S as bundlerPin, f as ccacheEnabled, i as macosToolchain, m as detectXcodeMajor, n as androidToolchain, r as iosToolchain, t as androidRequirements } from "./toolchain-CNIBTIOv.mjs";
13
- import { c as offloadCheck, f as simulatorRuntime, n as inspectDeviceHostMachines, v as inspectBuildMachines, x as realIo } from "./machines-C2XiNwh9.mjs";
12
+ import { C as podInstallCommand, D as projectCmakeLauncher, S as bundlerPin, f as ccacheEnabled, i as macosToolchain, m as detectXcodeMajor, n as androidToolchain, r as iosToolchain, t as androidRequirements } from "./toolchain-CdrxgUeA.mjs";
13
+ import { S as realIo, g as inspectBuildMachines, o as offloadCheck, u as simulatorRuntime, y as inspectDeviceHostMachines } from "./client-CxNotugx.mjs";
14
14
  import { a as findChrome, t as CHROME_INSTALL_REMEDY } from "./chrome-BrcVWQyD.mjs";
15
- import { i as countLiveOwnedDevices } from "./device-capacity-D0GWHnTM.mjs";
16
- import { d as androidPathRoomRemedy, l as androidPathRoom, n as apkOutputsDir, t as androidSdkRefusal, u as androidPathRoomMessage } from "./gradle-D7-L2Th3.mjs";
17
- import { g as resolveRuntime, m as resolveDeviceType } from "./support-BJPgYCu-.mjs";
15
+ import { i as countLiveOwnedDevices } from "./device-capacity-ZC4XSZ4R.mjs";
16
+ import { d as androidPathRoomRemedy, l as androidPathRoom, n as apkOutputsDir, t as androidSdkRefusal, u as androidPathRoomMessage } from "./gradle-bsBRy6i9.mjs";
17
+ import { g as resolveRuntime, m as resolveDeviceType } from "./support-BE-tbOP9.mjs";
18
18
  import { f as resolveEasCliBin, i as checkEasAuth$1, l as ownerFromConfig, u as providerFromConfig } from "./remote-cache-Ci4DQYYj.mjs";
19
19
  import { _ as easCliSupport, g as MIN_EAS_CLI_SIMULATOR_VERSION, s as readInstalledEasCliVersion, v as easCliUpgradeRemedy } from "./device-remote-hFSkpfQu.mjs";
20
20
  import { n as inspectStimVersions, t as compareStimVersions } from "./stim-installations-QMEI32v1.mjs";
@@ -672,13 +672,13 @@ function checkOffloadCandidate(placements, machines, peers, now) {
672
672
  if (average <= 18e4) return null;
673
673
  return {
674
674
  code: "offload-candidate",
675
- ...finding("note", "Builds could run on another Mac", `Cold builds averaged ~${Math.round(average / 6e4)} min over ${cold.length} builds this week.`, "In Stim Desktop, open Settings > Build machines > Add.")
675
+ ...finding("note", "Builds could run on another Mac", `Cold builds averaged ~${Math.round(average / 6e4)} min over ${cold.length} builds this week.`, "In Stim Desktop, open Settings > Remote Macs > Add.")
676
676
  };
677
677
  }
678
678
  function readOffloadCandidate(tailnetStatus, now, host) {
679
679
  if (host !== "darwin") return null;
680
680
  try {
681
- const entries = loadConfig$1()?.offload?.machines;
681
+ const entries = loadConfig$1()?.remote?.machines;
682
682
  const machines = Array.isArray(entries) ? entries.filter((entry) => typeof entry === "string") : [];
683
683
  const placements = readStats().record?.placements ?? [];
684
684
  if (machines.length || placements.length < 3) return null;
@@ -1506,7 +1506,7 @@ function applySandboxFix(root, env = process.env) {
1506
1506
  console.error(chalk.dim("Added writes to Stim's state directory, the simulator XPC service, and local port binding. Claude Code reads project settings from the directory a session starts in, so this file only counts for sessions rooted there. Restart the session for it to take effect."));
1507
1507
  }
1508
1508
  function doctorCommand(program, version, inspectVersions = inspectStimVersions, host = process.platform) {
1509
- program.command("doctor").description("Inspect the source checkout and report project state that can make native worktrees slow or invalid. The checkout is left untouched unless --fix is passed; --platform filters native findings. Each run in a React Native or Expo app is recorded in Stim state so guide can say when doctor is due.").option("--json", "print the findings as JSON").option("--platform <platform>", "report shared findings plus only this native platform: ios or android", parseDoctorPlatform).option("--fix", "repair the sandbox allowance when the report names it, and stale Android .cxx configurations in this checkout; ask each machine in offload.machines for build access. Stop native builds first. Generated CMake output must be ignored and untracked; custom launcher settings and source files are preserved.").action(async (opts) => {
1509
+ program.command("doctor").description("Inspect the source checkout and report project state that can make native worktrees slow or invalid. The checkout is left untouched unless --fix is passed; --platform filters native findings. Each run in a React Native or Expo app is recorded in Stim state so guide can say when doctor is due.").option("--json", "print the findings as JSON").option("--platform <platform>", "report shared findings plus only this native platform: ios or android", parseDoctorPlatform).option("--fix", "repair the sandbox allowance when the report names it, and stale Android .cxx configurations in this checkout; ask each remote Mac in remote.machines for build and device-host approval. Stop native builds first. Generated CMake output must be ignored and untracked; custom launcher settings and source files are preserved.").action(async (opts) => {
1510
1510
  const root = findProjectRoot$1(process.cwd());
1511
1511
  if (!root) {
1512
1512
  refuseNoProject({ json: Boolean(opts.json) });
@@ -1564,13 +1564,14 @@ function doctorCommand(program, version, inspectVersions = inspectStimVersions,
1564
1564
  local: macosToolchain()
1565
1565
  }] : []
1566
1566
  ];
1567
- const buildMachines = await inspectBuildMachines({
1567
+ const remoteMachines = await inspectBuildMachines({
1568
1568
  fix: opts.fix === true,
1569
1569
  check: checksIos || checksAndroid || checksMacos ? offloadCheck(root, offloadTargets) : null
1570
1570
  });
1571
- findings.push(...buildMachines.findings);
1571
+ findings.push(...remoteMachines.findings);
1572
1572
  const deviceHosts = await inspectDeviceHostMachines({ fix: opts.fix === true });
1573
- findings.push(...deviceHosts.findings);
1573
+ const reported = new Set(remoteMachines.findings.map((each) => each.title));
1574
+ findings.push(...deviceHosts.findings.filter((each) => !reported.has(each.title)));
1574
1575
  const agentDriver = inspectHostedAgentDriver();
1575
1576
  if (agentDriver) findings.push(agentDriver);
1576
1577
  const maintenance = maintenanceStatus();
@@ -1589,7 +1590,7 @@ function doctorCommand(program, version, inspectVersions = inspectStimVersions,
1589
1590
  ...maintenance,
1590
1591
  logPath: maintenanceNdjsonFile()
1591
1592
  },
1592
- buildMachines: buildMachines.machines,
1593
+ remoteMachines: remoteMachines.machines,
1593
1594
  deviceHosts: deviceHosts.machines,
1594
1595
  findings
1595
1596
  }));
@@ -6,21 +6,21 @@ import { h as shortUdid, o as formatLongDuration, u as plural } from "./command-
6
6
  import { _t as resolveFullRef, bt as sourceCheckoutOf, ct as hasUncommittedWork, dt as listWorktrees, ot as hasPopulatedSubmodules, rt as dirtyPaths, xt as unpushedCommits } from "./settings-Cfd-0r2d.mjs";
7
7
  import { r as detectIsExpo, s as findProjectRoot$1 } from "./project-D47Rh0ly.mjs";
8
8
  import { C as workspaceStateFile, s as workspaceLastUsed, v as workspaceDir, w as withDirLock$1, x as workspaceLogsDir$1 } from "./workspace-state-DqcCbpE7.mjs";
9
- import { A as includesWorkspaceOutputs, C as findStaleProjectDevices, D as includesArchives, E as emptyCaches, F as selectsBeyondCaches, G as memoryWorkPending, H as memoryLines, I as trimCaches, J as phase, K as reclaimMemory, M as planCacheEmptying, N as previewScopedEmptying, O as includesParkedDevices, P as selectCaches, Q as sizeCaches, S as findStaleDeviceRecords, T as withAndroidAvdSizes, U as memoryScope, V as memoryCacheKind, W as memorySweepIsScoped, Z as discoverCaches, _ as describeParkedSims, a as machineNumber, b as eraseParkedDevices, d as collectDeviceLeases, f as collectParkedAvds, g as deleteProjectDevices, h as deleteParkedSims, j as isWorkspacesScope, k as includesRecordings, m as deleteParkedAvds, p as collectParkedSims, q as scopedMemoryReport, u as DEVICE_LIST_TIMEOUT_MS, v as describeUnverifiableDevices, w as unverifiedDeviceCommand, x as findOrphanedDevices, y as deviceSweepIsScoped, z as collectMemoryReport } from "./budget-DM984mnd.mjs";
9
+ import { $ as sizeCaches, A as includesWorkspaceOutputs, B as collectMemoryReport, C as findStaleProjectDevices, D as includesArchives, E as emptyCaches, F as selectsBeyondCaches, G as memorySweepIsScoped, H as memoryCacheKind, I as trimCaches, J as scopedMemoryReport, K as memoryWorkPending, L as parseArchiveSelector, M as planCacheEmptying, N as previewScopedEmptying, O as includesParkedDevices, P as selectCaches, Q as discoverCaches, S as findStaleDeviceRecords, T as withAndroidAvdSizes, U as memoryLines, W as memoryScope, Y as phase, _ as describeParkedSims, a as machineNumber, b as eraseParkedDevices, d as collectDeviceLeases, f as collectParkedAvds, g as deleteProjectDevices, h as deleteParkedSims, j as isWorkspacesScope, k as includesRecordings, m as deleteParkedAvds, p as collectParkedSims, q as reclaimMemory, u as DEVICE_LIST_TIMEOUT_MS, v as describeUnverifiableDevices, w as unverifiedDeviceCommand, x as findOrphanedDevices, y as deviceSweepIsScoped } from "./budget-CUDz870h.mjs";
10
10
  import { a as takeGcResults, i as recordGcResult, n as withIdleWorkspace, o as canonicalPath, r as workspaceInUse } from "./in-use-CvGOUn-x.mjs";
11
11
  import { d as removeExpiredLease, h as listBuildLocks, i as listLeaseFiles, r as leaseIsExpired } from "./device-lease-DpoS36_u.mjs";
12
12
  import { n as listBuildSlots } from "./build-slots-41v_d2x9.mjs";
13
13
  import { n as readCreatedDevices$1, t as forgetCreatedDevice } from "./created-devices-CpvzBL25.mjs";
14
14
  import { A as listAvds, H as parseAvdSystemImage, I as ownedAvdDirectory, M as listOrphanedAvdDirectories, V as parseAvdDeviceProfile, _ as avdStorageRoots, at as isStimOwnedSim, d as androidToolPath, ft as parkedMaxSetting, it as isStimOwnedAvd, j as listInstalledSystemImages, m as avdNameAbsent, o as androidHome, ot as POOL_SETTING_REMEDY, p as avdIniPaths, pt as readParked, z as ownedAvdSerialResolver } from "./android-B_YNZy61.mjs";
15
15
  import { u as listAllIosSims } from "./ios-DSfnPfse.mjs";
16
- import { a as parseIdleDuration, o as shutDownIdleDevices, r as idleDeviceLines, t as collectIdleDevices } from "./idle-B2m-Ovod.mjs";
16
+ import { a as parseIdleDuration, o as shutDownIdleDevices, r as idleDeviceLines, t as collectIdleDevices } from "./idle-BXG__1BA.mjs";
17
17
  import { a as collectWorkspaceOutputs, c as listWorkspaceDirs, i as collectOrphanedWorkspaces, l as rootPresence, n as WORKSPACE_OUTPUT_DIRS, o as deleteOrphanedWorkspaces, r as clearWorkspaceOutputs, s as isInsideWorkspaces, t as REBUILD_COST, u as sizeText } from "./workspaces-Bcib97-6.mjs";
18
- import { n as previewMaintenance } from "./preview-CxPRIEht.mjs";
18
+ import { n as previewMaintenance } from "./preview-C_JjkEy4.mjs";
19
19
  import { r as readCollectors } from "./ownership-DyRQru0q.mjs";
20
20
  import { f as resolveEasCliBin } from "./remote-cache-Ci4DQYYj.mjs";
21
21
  import { C as listOwnedSessionsArgs, D as verifyStoppedSession, E as stopSessionArgs, S as isDefinitiveMissingSessionError, T as parseSessionListPage, b as getSessionArgs, d as withRemoteSessionLock, f as withEasProjectLock, h as removeEasSessionClaim, m as readEasSessionLedger$1, p as easMachineStateRoot$1, x as inspectSessionForTeardown, y as findOrphanedOwnedSessions } from "./device-remote-hFSkpfQu.mjs";
22
22
  import { o as fetchDefaultBranch, s as mergeState } from "./warm-progress-DF4JRvYI.mjs";
23
- import { _ as deleteSelectedArchives, f as removeWorktreeTarget, g as reclaimProject, h as describeDereferenced, i as matchWorktreeEntry, n as excludePodChurn, o as reclaimKeys, r as excludeWatchmanCookies, v as sweepArchiveStaging } from "./worktree-ZpZR3S1k.mjs";
23
+ import { _ as deleteSelectedArchives, f as removeWorktreeTarget, g as reclaimProject, h as describeDereferenced, i as matchWorktreeEntry, n as excludePodChurn, o as reclaimKeys, r as excludeWatchmanCookies, v as sweepArchiveStaging } from "./worktree-AK_m-d_m.mjs";
24
24
  import { i as getSwiftpmCacheUsage, n as swiftpmCacheLines, r as getAgentDeviceUsage, t as agentDeviceLines } from "./agent-device-usage-output-BK41vnzN.mjs";
25
25
  import { existsSync, lstatSync, readFileSync, readdirSync, rmSync, statSync } from "node:fs";
26
26
  import { basename, dirname, join } from "node:path";
@@ -40,10 +40,11 @@ function stagingOrNone() {
40
40
  }
41
41
  }
42
42
  function collectArchives(scope, olderThan, now) {
43
- const wanted = scope.trim().toLowerCase();
44
43
  const records = readArchives();
45
- const id = wanted.startsWith("archived:") ? scope.trim().slice(9) : null;
46
- const kind = wanted === "archived-logs" ? "logs" : wanted === "archived-recordings" ? "recordings" : wanted === "archived-agent" ? "agentActions" : null;
44
+ const { kind, id } = parseArchiveSelector(scope) ?? {
45
+ kind: null,
46
+ id: null
47
+ };
47
48
  const match = id !== null ? records.find((record) => record.id.toLowerCase() === id.toLowerCase()) : null;
48
49
  return {
49
50
  records: records.filter((record) => id === null || record.id === match?.id).map((record) => ({
@@ -3155,7 +3156,7 @@ function gcCommand(program) {
3155
3156
  const n = parseInt(v, 10);
3156
3157
  if (!Number.isFinite(n) || String(n) !== String(v).trim()) throw new InvalidArgumentError("must be a whole number of days, e.g. --older-than 30");
3157
3158
  return n;
3158
- }).option("--cache <name>", "act on the shared caches whose name or directory contains <name>, every cache, the workspace build outputs and the device recordings with --cache all, only the workspace build outputs with --cache workspaces, only the device recordings with --cache recordings, only the parked simulators and emulators with --cache parked, the watchman daemon and its stale roots with --cache watchman, or the Gradle and Kotlin compile daemons with --cache gradle-daemons; archived, archived:<id>, archived-logs, archived-recordings and archived-agent select archived history explicitly; --cache all excludes archives. all, workspaces, recordings, parked, archived, archived:<id>, archived-logs, archived-recordings, archived-agent, watchman and gradle-daemons are reserved names that never select a single cache, and --cache all never includes watchman or gradle-daemons. With --delete they are emptied whole (a parked device is erased and stays parked, watchman loses its stale roots and shuts down only when no client uses it, and only daemons proven idle stop), which is the only way to clear an index-backed cache; add --older-than <days> to trim them by age instead. Archive ids ignore --older-than; archived and per-kind archive selectors filter by removal age. Only those caches are reported; other devices and project entries are not inspected. Caches outside the config dir are refused while STIM_HOME is set.", (v) => {
3159
+ }).option("--cache <name>", "act on the shared caches whose name or directory contains <name>, every cache, the workspace build outputs and the device recordings with --cache all, only the workspace build outputs with --cache workspaces, only the device recordings with --cache recordings, only the parked simulators and emulators with --cache parked, the watchman daemon and its stale roots with --cache watchman, or the Gradle and Kotlin compile daemons with --cache gradle-daemons; archived, archived:<id>, archived-logs, archived-recordings and archived-agent select archived history explicitly, and the three kind selectors also take :<id> (archived-logs:<id>) to clear one kind of one archive; --cache all excludes archives. all, workspaces, recordings, parked, archived, archived:<id>, archived-logs, archived-recordings, archived-agent, their :<id> forms, watchman and gradle-daemons are reserved names that never select a single cache, and --cache all never includes watchman or gradle-daemons. With --delete they are emptied whole (a parked device is erased and stays parked, watchman loses its stale roots and shuts down only when no client uses it, and only daemons proven idle stop), which is the only way to clear an index-backed cache; add --older-than <days> to trim them by age instead. Archive ids, including the :<id> of a kind selector, ignore --older-than; archived and per-kind archive selectors without an id filter by removal age. Only those caches are reported; other devices and project entries are not inspected. Caches outside the config dir are refused while STIM_HOME is set.", (v) => {
3159
3160
  if (!v.trim()) throw new InvalidArgumentError("must name a cache, e.g. --cache \"compilation cache\"");
3160
3161
  return v;
3161
3162
  }).option("--idle <duration>", "shut down (never delete) owned simulators and emulators that have had no driver, claim, or activity for at least <duration>, such as 30m, 2h, or 1d; acts without --delete", (v) => {
@@ -3,7 +3,7 @@ import { n as stripAnsi, r as waitForChild, t as createLineReader } from "./proc
3
3
  import { l as phaseLine } from "./command-output-CDAIFD-8.mjs";
4
4
  import { a as spawnDeclared } from "./spawn-claims-D0XfSe8u.mjs";
5
5
  import { o as androidHome } from "./android-B_YNZy61.mjs";
6
- import { O as readCcacheActivity, T as CCACHE_UNAVAILABLE, u as HEARTBEAT_INTERVAL_MS, y as startBuildHeartbeat } from "./toolchain-CNIBTIOv.mjs";
6
+ import { O as readCcacheActivity, T as CCACHE_UNAVAILABLE, u as HEARTBEAT_INTERVAL_MS, y as startBuildHeartbeat } from "./toolchain-CdrxgUeA.mjs";
7
7
  import { createHash } from "node:crypto";
8
8
  import { existsSync, mkdirSync, readFileSync, readdirSync, rmSync, statSync } from "node:fs";
9
9
  import { dirname, isAbsolute, join, relative, sep } from "node:path";