stim 1.23.1 → 1.25.0

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 (174) hide show
  1. package/README.md +3 -2
  2. package/dist/{acquire-artifact-BzYRDgaP.mjs → acquire-artifact-zA4S7RHE.mjs} +2 -2
  3. package/dist/{act-vxiMwdf5.mjs → act-BbHS3oV8.mjs} +41 -26
  4. package/dist/{activity-BpWUPgUm.mjs → activity-BpjwrQXU.mjs} +6 -6
  5. package/dist/{agent-device-usage-output-CUlLsbRt.mjs → agent-device-usage-output-Bnkerfod.mjs} +5 -5
  6. package/dist/{android-DtfRGLcc.mjs → android-BGwuK3Mc.mjs} +75 -50
  7. package/dist/{android-CLi6DSiS.mjs → android-CNZgRC-4.mjs} +5 -5
  8. package/dist/{android-C7sVmyI9.mjs → android-Cjcj8MCw.mjs} +140 -46
  9. package/dist/{android-cas-ngferVq2.mjs → android-cas-BVqh2Zep.mjs} +3 -3
  10. package/dist/android-cas-compiler.mjs +1 -1
  11. package/dist/{android-project-DVWyCbWU.d.mts → android-project-CTYaETc0.d.mts} +6 -2
  12. package/dist/{android-DR5lZ2Az.mjs → android-saBeB4lr.mjs} +13 -3
  13. package/dist/api.d.mts +22 -5
  14. package/dist/api.mjs +32 -31
  15. package/dist/{artifact-Xvgibgzq.mjs → artifact-Co8zixVx.mjs} +19 -17
  16. package/dist/{artifact-DBI3DALs.mjs → artifact-DN8JNwqS.mjs} +18 -17
  17. package/dist/{artifact-platform-CXcmX_j3.mjs → artifact-platform-CMRc0M_r.mjs} +3 -3
  18. package/dist/{browser-web-BJN9ZHxB.mjs → browser-web-CCgZsHmI.mjs} +16 -17
  19. package/dist/{budget-3ivAK99e.mjs → budget-HyShrIpL.mjs} +149 -47
  20. package/dist/{build-Dv9s8Fz-.mjs → build-CAiw8Ezm.mjs} +33 -29
  21. package/dist/{build-cache-Dv7RN200.mjs → build-cache-CKCzxzxA.mjs} +172 -21
  22. package/dist/{build-plan-BmbdHQbr.mjs → build-plan-zCuHGlA8.mjs} +8 -7
  23. package/dist/{cache-manifest-DSeQjt-Q.mjs → cache-manifest-BPXRONJz.mjs} +1 -1
  24. package/dist/cache-manifest.mjs +1 -1
  25. package/dist/{ccache-CH2EWGPB.mjs → ccache-h1FKhZeg.mjs} +6 -6
  26. package/dist/{cdp-3fwICjzi.mjs → cdp-BG3FJCCx.mjs} +1 -1
  27. package/dist/{chrome-Bbw689-6.mjs → chrome-BvV8ssI3.mjs} +1 -1
  28. package/dist/{cli-BkK6Wr5i.mjs → cli-C4w607Pz.mjs} +20 -20
  29. package/dist/cli.mjs +1 -1
  30. package/dist/{client-B4MMzfo_.mjs → client-BQsmyp_-.mjs} +274 -39
  31. package/dist/collector-run.mjs +6 -6
  32. package/dist/{command-output-YKGWivpG.mjs → command-output-BBvS1H6v.mjs} +3 -2
  33. package/dist/{config-DlrsduwG.mjs → config-BZhXY15H.mjs} +3 -3
  34. package/dist/{created-devices-x9rN6bhs.mjs → created-devices-D2Aca-xu.mjs} +6 -2
  35. package/dist/{dependency-state-1I9KZT1Y.mjs → dependency-state-BwNCYG5Q.mjs} +2 -2
  36. package/dist/{detached-entry-BwNEtIrP.mjs → detached-entry-KmieOKgN.mjs} +1 -1
  37. package/dist/{dev-client-BFxiDpkf.mjs → dev-client-CHoXXZeg.mjs} +3 -3
  38. package/dist/{device-CiNYxqp6.mjs → device-B9FqTBYW.mjs} +81 -54
  39. package/dist/{device-B7ljwccX.mjs → device-F5-4z9ef.mjs} +16 -16
  40. package/dist/{device-capacity-DH0QsZYZ.mjs → device-capacity-ZYaRALv5.mjs} +20 -16
  41. package/dist/device-host-worker.mjs +17 -17
  42. package/dist/{device-ios-CbVDtDIy.mjs → device-ios-DkHBrmvH.mjs} +32 -50
  43. package/dist/{device-lease-run-DXPSwdbb.mjs → device-lease-run-ogEeJ62K.mjs} +6 -6
  44. package/dist/{device-pool-B4iOXIrD.mjs → device-pool-BIg8MU8l.mjs} +3 -3
  45. package/dist/{doctor-DRu-8ld6.mjs → doctor-A_Nr_fDe.mjs} +1 -1
  46. package/dist/{doctor-HUC1igzw.mjs → doctor-Bm8TVpGn.mjs} +37 -31
  47. package/dist/{doctor-fingerprint-DZLoYFVb.mjs → doctor-fingerprint-zlujA1Gs.mjs} +1 -1
  48. package/dist/doctor-fingerprint.mjs +1 -1
  49. package/dist/{doctor-C6t4Maue.mjs → doctor-k3P3PizH.mjs} +14 -14
  50. package/dist/{doctor-watchman-iGBpC6KM.mjs → doctor-watchman-BovI1y3-.mjs} +5 -5
  51. package/dist/{eas-build-DMWSSvxq.mjs → eas-build-CyDKNTBP.mjs} +4 -4
  52. package/dist/{eas-fallback-vKlrqxgE.mjs → eas-fallback-gaZi-dJL.mjs} +16 -15
  53. package/dist/{eas-session-ledger-BQF9Yyy9.mjs → eas-session-ledger-BMCA1gdO.mjs} +12 -8
  54. package/dist/{error-diagnostics-DYsjJIHz.mjs → error-diagnostics-B1Mj_-7h.mjs} +17 -42
  55. package/dist/{errors-ccaPc4ox.mjs → errors-DHm_U5gv.mjs} +2 -1
  56. package/dist/{exec-DEoAhcze.mjs → exec-VFRpu1iA.mjs} +116 -28
  57. package/dist/{gc-BW8E1uSC.mjs → gc-B9jcnmIk.mjs} +205 -28
  58. package/dist/{gc-dDE4QPVu.mjs → gc-eaz403W6.mjs} +2 -2
  59. package/dist/{guide-DYYEO3Wz.mjs → guide-DR0K0xW9.mjs} +328 -89
  60. package/dist/{hosted-android-xcfgCgSF.mjs → hosted-android-Bvb2-ZxD.mjs} +4 -4
  61. package/dist/{hosted-client-Bt-tndxV.mjs → hosted-client-rsRqysJc.mjs} +4 -4
  62. package/dist/{hosted-ios-y19jCYFF.mjs → hosted-ios-RtVcJH3u.mjs} +1 -1
  63. package/dist/{hosted-logs-DzJKzKlj.mjs → hosted-logs-CWKGYWNX.mjs} +11 -6
  64. package/dist/{hosted-macos-BJusKvqL.mjs → hosted-macos-d0pv9Tth.mjs} +7 -7
  65. package/dist/{hosted-native-BmQC6U_x.mjs → hosted-native-BxTizGU2.mjs} +58 -11
  66. package/dist/{idle-shutdown-CJmUOV5x.mjs → idle-shutdown-BIyfl0Zj.mjs} +10 -10
  67. package/dist/{ios-hcBpnEGk.mjs → ios-BQzvJlzw.mjs} +122 -17
  68. package/dist/{ios-CWjqfSm_.mjs → ios-BRVM8b0P.mjs} +81 -49
  69. package/dist/{ios-DTOYZGMJ.mjs → ios-Dvt97HgQ.mjs} +8 -8
  70. package/dist/{ios-xtlRHaeB.mjs → ios-ENC4sRPA.mjs} +1 -1
  71. package/dist/{ios-device-BXZ0c7Kb.mjs → ios-device-B6HK951C.mjs} +1 -1
  72. package/dist/{ios-device-DFGuwF4U.mjs → ios-device-CKSvk0bu.mjs} +3 -3
  73. package/dist/{ios-project-CSZYI1iu.mjs → ios-project-DCUDo06I.mjs} +5 -5
  74. package/dist/{ios-signing-BtAffm0A.mjs → ios-signing-4c_qXvQm.mjs} +2 -2
  75. package/dist/{ios-state-Dtw5K2aI.mjs → ios-state-CT9nV5SP.mjs} +15 -7
  76. package/dist/{js-swap-BSBHldmm.mjs → js-swap-Z9HbC4cj.mjs} +7 -6
  77. package/dist/{launch-D-zq8SHG.mjs → launch-D0lPvFFu.mjs} +49 -30
  78. package/dist/{launch-CP2wDCVd.mjs → launch-DscF1QfM.mjs} +52 -50
  79. package/dist/{logs-pNvA2hHK.mjs → logs-BsIRre8x.mjs} +16 -9
  80. package/dist/{logs-By5aw3g9.mjs → logs-Crs9y34Z.mjs} +8 -6
  81. package/dist/{macos-CPMahOC2.mjs → macos-CcUlJPMu.mjs} +1 -1
  82. package/dist/{macos-C67FZ2ft.mjs → macos-D477nfzH.mjs} +49 -42
  83. package/dist/macos-run.mjs +1 -1
  84. package/dist/maintenance-run.mjs +7 -7
  85. package/dist/{metro-DiXtA3Ty.mjs → metro-1pJgCX4U.mjs} +4 -4
  86. package/dist/{metro-gateway-CKZqKqx7.mjs → metro-gateway-Bp9gJQAN.mjs} +3 -4
  87. package/dist/{named-ports-DkEzOfzO.mjs → named-ports-BVbn8SvC.mjs} +3 -3
  88. package/dist/{native-android-_MWSs3PP.mjs → native-android-BvMizJn1.mjs} +17 -17
  89. package/dist/{native-gradle-artifact-inputs-DHFnmrVf.mjs → native-gradle-artifact-inputs-BJscK4vN.mjs} +5 -5
  90. package/dist/{native-run-Dv88i0aU.mjs → native-run-D5OJsGwA.mjs} +6 -6
  91. package/dist/{native-runtime-DBRfY_PN.mjs → native-runtime-B9w_Qyz3.mjs} +10 -9
  92. package/dist/{native-source-Y0yLhFyQ.mjs → native-source-D-4Dh4JU.mjs} +7 -4
  93. package/dist/{native-xcode-inputs-CqViUh3r.mjs → native-xcode-inputs-Cv4l-obn.mjs} +2 -2
  94. package/dist/{native-xcode-ios-vFgqL_yS.mjs → native-xcode-ios-DGrg90hE.mjs} +21 -20
  95. package/dist/offload-worker.d.mts +12 -4
  96. package/dist/offload-worker.mjs +78 -43
  97. package/dist/{operation-exec-BW0em61G.mjs → operation-exec-CUZifp6Z.mjs} +2 -25
  98. package/dist/{ownership-C5fo5Edb.mjs → ownership-jxxz-19m.mjs} +3 -3
  99. package/dist/{page-DBL2PiUU.mjs → page-CzEA_-5_.mjs} +2 -3
  100. package/dist/phone-reverses-CYb7RRAx.mjs +57 -0
  101. package/dist/{placement-log-BnGgJRRZ.mjs → placement-log-DjOXJRIH.mjs} +1 -1
  102. package/dist/{plan-placement-cr0fEU7b.mjs → plan-placement-BqKgKHCi.mjs} +3 -3
  103. package/dist/{ports-DpXjKkSV.mjs → ports-DtS1Amb0.mjs} +3 -3
  104. package/dist/{prebuild-BligW0QS.mjs → prebuild-JUaqOLpc.mjs} +14 -9
  105. package/dist/{project-DhCtQWWU.mjs → project-BiC68mIp.mjs} +21 -17
  106. package/dist/{pull-request-W1IuLXDt.mjs → pull-request-CbNlkFok.mjs} +2 -2
  107. package/dist/pull-requests.mjs +1 -1
  108. package/dist/{react-native-android-ZlhQfhvq.mjs → react-native-android-DRYqoJc4.mjs} +76 -32
  109. package/dist/{react-native-build-CelbTO_y.mjs → react-native-build-CwZB-agu.mjs} +23 -20
  110. package/dist/{react-native-doctor-LTIaP7lv.mjs → react-native-doctor-BCrytK7h.mjs} +10 -9
  111. package/dist/{react-native-ios-C5W0SA6f.mjs → react-native-ios-Cr1buNFo.mjs} +41 -24
  112. package/dist/{recordings-CQmfzAh7.mjs → recordings-BaoQ0t-J.mjs} +1 -1
  113. package/dist/{registration-BcRgF6Ox.mjs → registration-CN6nlhcD.mjs} +1 -1
  114. package/dist/{reload-QcwnYLYV.mjs → reload-Beftw2X3.mjs} +1 -1
  115. package/dist/{reload-COJWTbae.mjs → reload-FbSgMF8x.mjs} +144 -42
  116. package/dist/{remote-DR8qUERM.mjs → remote-BuZj6AyU.mjs} +16 -7
  117. package/dist/{result-utnBea7x.mjs → result-CR2vk2cj.mjs} +41 -18
  118. package/dist/{run-DidHghD1.mjs → run-BtzE09Dl.mjs} +2 -2
  119. package/dist/{selection-DSMbWEX2.mjs → selection-D5cxEl3t.mjs} +13 -7
  120. package/dist/{server-bare-CafzuyFB.mjs → server-bare-CH9X0RLn.mjs} +56 -4
  121. package/dist/{server-command-B9o92sLM.mjs → server-command-CaBbDNU2.mjs} +5 -5
  122. package/dist/server-expo-C16Zf2k7.mjs +2 -0
  123. package/dist/{server-expo-BXrWxNYh.mjs → server-expo-Ck8EIidM.mjs} +14 -9
  124. package/dist/{settings-C7O8A6ZI.mjs → settings-B5tCoq9N.mjs} +132 -39
  125. package/dist/{settings-PfJx8uK1.mjs → settings-DzH9mGQZ.mjs} +1 -1
  126. package/dist/{settings-write-Chuy7Cte.mjs → settings-write-n0zwfohx.mjs} +7 -7
  127. package/dist/settings.schema.json +51 -0
  128. package/dist/{simslim-BNckWpXi.mjs → simslim-BjxszUAb.mjs} +22 -7
  129. package/dist/{slot-launch-B7AuoWJv.mjs → slot-launch-QeuJMlnJ.mjs} +6 -6
  130. package/dist/{stage-C4u17aES.mjs → stage-D8xlRU2D.mjs} +2 -3
  131. package/dist/{start-BL_BsiWt.mjs → start-C1JLjkNw.mjs} +1 -1
  132. package/dist/{start-CU8mCPC7.mjs → start-YMpNwLhh.mjs} +75 -35
  133. package/dist/{state--smjFSTL.mjs → state-DMRNP7-4.mjs} +4 -4
  134. package/dist/{state-08I3hw3_.mjs → state-DPaM3u5K.mjs} +2 -2
  135. package/dist/{stats-CO6sK0Nh.mjs → stats-CP7STzZw.mjs} +5 -5
  136. package/dist/{stats-report-BzaPrRm6.mjs → stats-report-n2U5plhk.mjs} +1 -1
  137. package/dist/{status-_WPHzVft.mjs → status-CRLiJ-O_.mjs} +24 -24
  138. package/dist/{status-BRROykC8.mjs → status-Fect2w9R.mjs} +1 -1
  139. package/dist/{status-CrJutl6-.mjs → status-cNw6i0_t.mjs} +1 -1
  140. package/dist/{status-watch-BHFasOZN.mjs → status-watch-Bc2J4TZn.mjs} +5 -5
  141. package/dist/status-worker.mjs +1 -1
  142. package/dist/stim-clonefile.c +18 -0
  143. package/dist/{stim-desktop-D5OGpYZM.mjs → stim-desktop-DS0mzR8U.mjs} +2 -2
  144. package/dist/{stop-iuFHjUST.mjs → stop-Br7LKxBE.mjs} +2 -2
  145. package/dist/{stop-CR5689oB.mjs → stop-COP6PQqw.mjs} +5 -5
  146. package/dist/{stop-BJ06ipTZ.mjs → stop-Db9Kh-UA.mjs} +109 -56
  147. package/dist/supervisor-run.mjs +17 -17
  148. package/dist/{support-CbXPbUMJ.mjs → support-Cxj9CmII.mjs} +6 -6
  149. package/dist/{support-TWuQlHQo.mjs → support-qKcbgmI5.mjs} +14 -11
  150. package/dist/{swiftpm-artifact-inputs-DFcGsXDP.mjs → swiftpm-artifact-inputs-iY9fsmOc.mjs} +4 -4
  151. package/dist/{swiftpm-macos-DbwGCpZg.mjs → swiftpm-macos-Bp_sn9P4.mjs} +15 -14
  152. package/dist/{toolchain-XkA2PfJZ.mjs → toolchain-DB1aeqxO.mjs} +1 -1
  153. package/dist/{toolchain-B9hCFCQw.mjs → toolchain-VzLJzZ7O.mjs} +69 -37
  154. package/dist/trigger-BLsHgAGR.mjs +2 -0
  155. package/dist/{trigger-Cbyc41d_.mjs → trigger-CBMe2YLH.mjs} +2 -2
  156. package/dist/{warm-progress-CA3TgT3-.mjs → warm-progress-BV3ZPmcY.mjs} +6 -6
  157. package/dist/{web-DRF_oFXk.mjs → web-B4Yjyt1G.mjs} +12 -10
  158. package/dist/web-DS4UDWvf.mjs +2 -0
  159. package/dist/web-run.mjs +8 -9
  160. package/dist/windows-report.mjs +12 -1
  161. package/dist/windows-report.ps1 +1 -1
  162. package/dist/{workspace-state-U08dEzhG.mjs → workspace-state-CPSp3mav.mjs} +11 -4
  163. package/dist/{workspaces-e41xsjKr.mjs → workspaces-C9w4aeXF.mjs} +36 -32
  164. package/dist/{worktree-B4Nj3EGS.mjs → worktree-CclFIe1Z.mjs} +324 -99
  165. package/dist/{worktree-BEwxVwKF.mjs → worktree-Ct9Gk3KL.mjs} +1 -1
  166. package/dist/{xcode-Rq744mBF.mjs → xcode-CiIIDnuD.mjs} +42 -28
  167. package/package.json +7 -7
  168. package/shim/bundle-response.cjs +53 -1
  169. package/shim/bundle-response.d.cts +1 -1
  170. package/shim/expo-metro-config.cjs +23 -1
  171. package/dist/native-gradle-inputs-Dnh84Zbd.mjs +0 -211
  172. package/dist/server-expo-Ddr8cG_c.mjs +0 -2
  173. package/dist/trigger-yb_nFzPF.mjs +0 -2
  174. package/dist/web-kDE9Myoy.mjs +0 -2
@@ -1,10 +1,9 @@
1
- import { t as getExecutor } from "./exec-DEoAhcze.mjs";
1
+ import { o as cancellableSleep, t as getExecutor } from "./exec-VFRpu1iA.mjs";
2
2
  import { n as stripAnsi, t as createLineReader } from "./process-output-Fpl8PYi8.mjs";
3
- import { u as cancellableSleep } from "./operation-exec-BW0em61G.mjs";
4
- import { q as resolveProjectSettings } from "./settings-C7O8A6ZI.mjs";
5
- import { C as resolvePackageJson } from "./project-DhCtQWWU.mjs";
3
+ import { J as resolveProjectSettings } from "./settings-B5tCoq9N.mjs";
4
+ import { C as resolvePackageJson } from "./project-BiC68mIp.mjs";
6
5
  import { r as createNdjsonWriter } from "./ndjson-CgE_o3Dl.mjs";
7
- import { a as expoMetroStoreEnv, c as registerMetroStore, f as resolveMetroSharedCache, i as expoMetroConfigPath, n as supervisorError, o as metroStoreConfirmedRoot, s as metroStoreRoot } from "./errors-ccaPc4ox.mjs";
6
+ import { a as expoMetroStoreEnv, c as registerMetroStore, f as resolveMetroSharedCache, i as expoMetroConfigPath, n as supervisorError, o as metroStoreConfirmedRoot, s as metroStoreRoot } from "./errors-DHm_U5gv.mjs";
8
7
  import { accessSync, constants, existsSync, readFileSync } from "node:fs";
9
8
  import { delimiter, dirname, join } from "node:path";
10
9
  import { LOG_ROTATE_BYTES } from "@stim-cli/core";
@@ -250,7 +249,7 @@ function recordFromLine(line, { stream = "stdout", source = "expo" } = {}) {
250
249
  if (!msg.trim()) return null;
251
250
  if (stream === "stderr" && msg.startsWith("stim-bundle-response: ")) try {
252
251
  const record = JSON.parse(msg.slice(22));
253
- if (record.src === "metro" && /^bundle_(response|prefetch)_(started|progress|finished|failed)$/.test(record.event) && ["ios", "android"].includes(record.platform) && typeof record.requestId === "string" && Number.isFinite(record.ts)) return record;
252
+ if (record.src === "metro" && /^(?:bundle_(?:response|prefetch)_(?:started|progress|finished|failed)|manifest_request_(?:started|finished|failed))$/.test(record.event) && ["ios", "android"].includes(record.platform) && typeof record.requestId === "string" && Number.isFinite(record.ts)) return record;
254
253
  } catch {}
255
254
  const confirmed = metroStoreConfirmedRoot(msg);
256
255
  if (confirmed) return {
@@ -274,6 +273,9 @@ function expoProxyEnv(env) {
274
273
  const publicUrl = env.STIM_METRO_PUBLIC_URL?.trim();
275
274
  return publicUrl ? { EXPO_PACKAGER_PROXY_URL: publicUrl.replace(/\/+$/, "") } : {};
276
275
  }
276
+ function expoTelemetryEnv(env) {
277
+ return env.EXPO_NO_TELEMETRY === void 0 ? { EXPO_NO_TELEMETRY: "1" } : {};
278
+ }
277
279
  const WAITING_ON_RE = /^Waiting on (\S+)/;
278
280
  const URL_SCHEME_RE = /^[a-z][a-z0-9+.-]*:\/\//i;
279
281
  const HTTP_SCHEME_RE = /^https?:\/\//i;
@@ -284,7 +286,7 @@ function parseExpoWaitingOnUrl(line) {
284
286
  if (HTTP_SCHEME_RE.test(url)) return url;
285
287
  return URL_SCHEME_RE.test(url) ? url.replace(/^[^:]+:/, "https:") : url;
286
288
  }
287
- function resolveMetroStoreInjection(root, { log, env, settings }) {
289
+ function resolveMetroStoreInjection(root, { log, env, settings, port }) {
288
290
  const sharedCache = resolveMetroSharedCache(settings);
289
291
  if (!sharedCache) log.write({
290
292
  src: "metro",
@@ -315,6 +317,7 @@ function resolveMetroStoreInjection(root, { log, env, settings }) {
315
317
  const storeRoot = sharedCache ? metroStoreRoot(root) : "";
316
318
  const additions = expoMetroStoreEnv({
317
319
  root,
320
+ port,
318
321
  storeRoot,
319
322
  adapterPath,
320
323
  existingOverride: env.EXPO_OVERRIDE_METRO_CONFIG
@@ -348,7 +351,8 @@ async function startExpoServer({ root, port, logsDir, writer = null, spawnFn = n
348
351
  const storeEnv = resolveMetroStoreInjection(root, {
349
352
  log,
350
353
  env: process.env,
351
- settings: settings ?? resolveProjectSettings(root).settings
354
+ settings: settings ?? resolveProjectSettings(root).settings,
355
+ port
352
356
  });
353
357
  const [command, commandArgs] = platform === "win32" && resolved.source === "package" ? [process.execPath, [bin, ...args]] : [bin, args];
354
358
  const node = withProjectNode(root, process.env);
@@ -370,6 +374,7 @@ async function startExpoServer({ root, port, logsDir, writer = null, spawnFn = n
370
374
  ...node.env,
371
375
  FORCE_COLOR: "0",
372
376
  ...expoProxyEnv(process.env),
377
+ ...expoTelemetryEnv(process.env),
373
378
  ...storeEnv,
374
379
  ...tunnel ? { EXPO_UNSTABLE_TUNNEL_V2: "1" } : {}
375
380
  }
@@ -393,4 +398,4 @@ async function startExpoServer({ root, port, logsDir, writer = null, spawnFn = n
393
398
  });
394
399
  }
395
400
  //#endregion
396
- export { withProjectNode as _, expoProxyEnv as a, inferLevel as c, parseExpoWaitingOnUrl as d, recordFromLine as f, unmetNodePin as g, projectNodeLine as h, expoBinRefusal as i, isBundleMarker as l, pathNodeVersion as m, expoBinFromPackage as n, expoSdkMajor as o, startExpoServer as p, expoBinPath as r, findBinUpward as s, cleanLine as t, isDevClientNavigationNotice as u, superviseChildServer as v };
401
+ export { unmetNodePin as _, expoProxyEnv as a, findBinUpward as c, isDevClientNavigationNotice as d, parseExpoWaitingOnUrl as f, projectNodeLine as g, pathNodeVersion as h, expoBinRefusal as i, inferLevel as l, startExpoServer as m, expoBinFromPackage as n, expoSdkMajor as o, recordFromLine as p, expoBinPath as r, expoTelemetryEnv as s, cleanLine as t, isBundleMarker as u, withProjectNode as v, superviseChildServer as y };
@@ -1,14 +1,15 @@
1
- import { n as isTimeoutError, r as WorkspaceProcessCleanupError, t as getExecutor } from "./exec-DEoAhcze.mjs";
2
- import { _ as loadConfig$1, d as getConfigDir, f as getConfigPath$1, h as getRepoSettings, m as getProjectSettings } from "./config-DlrsduwG.mjs";
3
- import { c as gitQuiet, f as throwIfCancelled, l as gitQuietAsync, o as git, r as childEnvironment, s as gitAsync } from "./operation-exec-BW0em61G.mjs";
1
+ import { c as throwIfCancelled, l as WorkspaceProcessCleanupError, n as isTimeoutError, t as getExecutor } from "./exec-VFRpu1iA.mjs";
2
+ import { _ as loadConfig$1, d as getConfigDir, f as getConfigPath$1, h as getRepoSettings, m as getProjectSettings } from "./config-BZhXY15H.mjs";
3
+ import { c as gitQuiet, l as gitQuietAsync, n as runOperationFileQuiet, o as git, r as childEnvironment, s as gitAsync, t as runOperationFile } from "./operation-exec-CUZifp6Z.mjs";
4
4
  import { accessSync, chmodSync, constants, lstatSync, mkdirSync, mkdtempSync, readdirSync, realpathSync, rmSync, statSync } from "node:fs";
5
5
  import { tmpdir } from "node:os";
6
6
  import { basename, dirname, isAbsolute, join, relative, resolve, sep } from "node:path";
7
- import { ambientEnv, buildCacheRoot } from "@stim-cli/core";
7
+ import { ambientEnv, buildCacheRoot, compiledHelper, configDir } from "@stim-cli/core";
8
8
  import { REMOTE_DEVICE_BACKENDS, SETTINGS, SETTING_GROUPS, TUNNEL_MODES, WEB_VIEWPORTS, acceptsShape, coerceSettingText, expectedShape, isLayeredSetting, settingDefinition, settingValueError } from "@stim-cli/core/state";
9
- import { dirname as dirname$1, isAbsolute as isAbsolute$1, join as join$1, normalize, relative as relative$1, resolve as resolve$1, sep as sep$1 } from "path";
9
+ import { basename as basename$1, dirname as dirname$1, isAbsolute as isAbsolute$1, join as join$1, normalize, relative as relative$1, resolve as resolve$1, sep as sep$1 } from "path";
10
+ import { fileURLToPath } from "node:url";
10
11
  import { existsSync as existsSync$1, lstatSync as lstatSync$1, readFileSync as readFileSync$1, readdirSync as readdirSync$1, realpathSync as realpathSync$1, statSync as statSync$1 } from "fs";
11
- import { chmod, lstat, mkdir, readdir, rm, utimes } from "node:fs/promises";
12
+ import { chmod, lstat, mkdir, readdir, realpath, rm, utimes } from "node:fs/promises";
12
13
  //#region src/temporary.ts
13
14
  function existingPath(path) {
14
15
  const missing = [];
@@ -107,6 +108,51 @@ async function removeTemporaryEntryAsync(path, signal) {
107
108
  signal?.throwIfAborted();
108
109
  }
109
110
  //#endregion
111
+ //#region src/clonefile.ts
112
+ const SOURCE = "stim-clonefile.c";
113
+ const COMPILE_TIMEOUT_MS = 12e4;
114
+ const PROBE_TIMEOUT_MS = 5e3;
115
+ function helperSource() {
116
+ const here = fileURLToPath(import.meta.url);
117
+ if (basename(dirname(here)) === "src") return fileURLToPath(new URL(`../helper/${SOURCE}`, import.meta.url));
118
+ return join(dirname(here), SOURCE);
119
+ }
120
+ /** The `stim-clonefile` helper, compiled on first use, or null off macOS, without the Command Line Tools, or when the compile fails. */
121
+ async function clonefileHelper(operation) {
122
+ if (process.platform !== "darwin") return null;
123
+ const exec = getExecutor();
124
+ if (!await runOperationFileQuiet(operation, exec, "xcode-select", ["-p"], {
125
+ timeoutMs: PROBE_TIMEOUT_MS,
126
+ cwd: operation.cwd
127
+ })) return null;
128
+ const source = helperSource();
129
+ try {
130
+ return await compiledHelper({
131
+ dir: join(configDir(), "helpers"),
132
+ name: "stim-clonefile",
133
+ inputs: [source],
134
+ version: "",
135
+ prune: false,
136
+ compile: async (output) => {
137
+ await runOperationFile(operation, exec, "xcrun", [
138
+ "clang",
139
+ "-O2",
140
+ "-o",
141
+ output,
142
+ source
143
+ ], {
144
+ timeoutMs: COMPILE_TIMEOUT_MS,
145
+ cwd: operation.cwd
146
+ });
147
+ }
148
+ });
149
+ } catch (error) {
150
+ if (error instanceof WorkspaceProcessCleanupError || error instanceof Error && "reportCleanup" in error) throw error;
151
+ operation.signal.throwIfAborted();
152
+ return null;
153
+ }
154
+ }
155
+ //#endregion
110
156
  //#region src/workspace/worktree.ts
111
157
  const CARRY_SKIP_BASENAMES = /* @__PURE__ */ new Set([
112
158
  ".DerivedData",
@@ -121,7 +167,7 @@ function isCarrySkipped(rel) {
121
167
  function nativePath(path) {
122
168
  return sep$1 === "/" ? path : path.replaceAll("/", sep$1);
123
169
  }
124
- async function gitReadAsync(dir, args, { removal, env, signal, declareFor, untrimmed }) {
170
+ async function gitReadAsync(dir, args, { removal, timeoutThrows, env, signal, declareFor, untrimmed }) {
125
171
  signal ??= getExecutor().reportSignal?.();
126
172
  try {
127
173
  return await gitAsync(dir, args, {
@@ -135,7 +181,7 @@ async function gitReadAsync(dir, args, { removal, env, signal, declareFor, untri
135
181
  } catch (error) {
136
182
  if (error instanceof WorkspaceProcessCleanupError || error instanceof Error && "reportCleanup" in error) throw error;
137
183
  signal?.throwIfAborted();
138
- if (removal && isTimeoutError(error)) throw error;
184
+ if ((removal || timeoutThrows) && isTimeoutError(error)) throw error;
139
185
  return null;
140
186
  }
141
187
  }
@@ -213,7 +259,8 @@ async function warmWorktreePaths(cwd, operation) {
213
259
  const options = {
214
260
  env: operation?.env,
215
261
  signal: operation?.signal,
216
- declareFor: operation
262
+ declareFor: operation,
263
+ timeoutThrows: true
217
264
  };
218
265
  const currentRoot = await repoRootAsync(cwd, options);
219
266
  if (!currentRoot) throw new Error("Not a git repository.");
@@ -334,28 +381,62 @@ function missingDestinationReason(target, rel) {
334
381
  }
335
382
  return lstatSync$1(join$1(target, rel), { throwIfNoEntry: false }) ? "exists" : null;
336
383
  }
337
- async function removeCopiedExclusionsAsync(path, rel, signal) {
384
+ const AUTOLINKING_PATH = [
385
+ "android",
386
+ "build",
387
+ "generated",
388
+ "autolinking"
389
+ ];
390
+ function knownCopiedPaths(rel) {
391
+ const segments = rel.split("/");
392
+ const paths = [];
393
+ if (segments.at(-1) === "node_modules") paths.push(".pnpm-store", "expo-modules-jsi/apple/.DerivedData");
394
+ for (let covered = 1; covered < AUTOLINKING_PATH.length; covered++) if (AUTOLINKING_PATH.slice(0, covered).every((segment, i) => segments.at(i - covered) === segment)) paths.push(AUTOLINKING_PATH.slice(covered).join("/"));
395
+ return paths;
396
+ }
397
+ function isMissingError(error) {
398
+ return error instanceof Error && "code" in error && (error.code === "ENOENT" || error.code === "ENOTDIR");
399
+ }
400
+ async function removeCopiedPath(root, rel, signal) {
338
401
  signal.throwIfAborted();
339
- const entries = await readdir(path, { withFileTypes: true });
340
- const excluded = entries.filter((entry) => isCarrySkipped(`${rel}/${entry.name}`));
341
- if (excluded.length) {
342
- const stat = await lstat(path);
343
- await chmod(path, stat.mode | 448);
344
- try {
345
- for (const entry of excluded) {
346
- signal.throwIfAborted();
347
- await removeTemporaryEntryAsync(join$1(path, entry.name), signal);
348
- }
349
- } finally {
350
- await utimes(path, stat.atime, stat.mtime);
351
- await chmod(path, stat.mode);
352
- }
402
+ const path = join$1(root, rel);
403
+ let parent;
404
+ try {
405
+ parent = await realpath(dirname$1(path));
406
+ } catch (error) {
407
+ if (isMissingError(error)) return;
408
+ throw error;
353
409
  }
354
- for (const entry of entries) {
355
- const child = `${rel}/${entry.name}`;
356
- if (entry.isDirectory() && !isCarrySkipped(child)) await removeCopiedExclusionsAsync(join$1(path, entry.name), child, signal);
410
+ const inside = relative$1(root, parent);
411
+ if (inside === ".." || inside.startsWith(`..${sep$1}`) || isAbsolute$1(inside)) return;
412
+ const stat = await lstat(parent);
413
+ const target = join$1(parent, basename$1(path));
414
+ try {
415
+ await lstat(target);
416
+ } catch (error) {
417
+ if (isMissingError(error)) return;
418
+ throw error;
419
+ }
420
+ await chmod(parent, stat.mode | 448);
421
+ try {
422
+ await removeTemporaryEntryAsync(target, signal);
423
+ } finally {
424
+ await utimes(parent, stat.atime, stat.mtime);
425
+ await chmod(parent, stat.mode);
357
426
  }
358
427
  }
428
+ async function removeKnownCopiedPaths(path, rel, signal) {
429
+ const paths = knownCopiedPaths(rel);
430
+ if (basename$1(rel) === "node_modules") {
431
+ const virtualStore = await readdir(join$1(path, ".pnpm")).catch((error) => {
432
+ if (isMissingError(error)) return [];
433
+ throw error;
434
+ });
435
+ for (const name of virtualStore) if (name.startsWith("expo-modules-jsi@")) paths.push(`.pnpm/${name}/node_modules/expo-modules-jsi/apple/.DerivedData`);
436
+ }
437
+ const root = await realpath(path);
438
+ for (const known of paths) await removeCopiedPath(root, known, signal);
439
+ }
359
440
  async function cloneIgnoredEntries({ root, target, patterns, operation }) {
360
441
  const options = {
361
442
  ...childEnvironment(operation.env),
@@ -377,6 +458,8 @@ async function cloneIgnoredEntries({ root, target, patterns, operation }) {
377
458
  const skipped = [];
378
459
  const failed = [];
379
460
  let cloned = true;
461
+ let helper;
462
+ const clonefile = () => helper ??= clonefileHelper(operation);
380
463
  for (const rel of entries) {
381
464
  operation.signal.throwIfAborted();
382
465
  const from = join$1(root, rel);
@@ -393,16 +476,23 @@ async function cloneIgnoredEntries({ root, target, patterns, operation }) {
393
476
  }
394
477
  await mkdir(dirname$1(to), { recursive: true });
395
478
  copying = true;
396
- try {
397
- await getExecutor().runFileAsync("cp", [
398
- "-Rc",
399
- from,
400
- to
401
- ], options);
402
- } catch (cause) {
403
- if (cause instanceof WorkspaceProcessCleanupError || cause instanceof Error && "reportCleanup" in cause) throw cause;
404
- operation.signal.throwIfAborted();
405
- await removeTemporaryEntryAsync(to);
479
+ const copiedWith = async (file, args) => {
480
+ try {
481
+ await getExecutor().runFileAsync(file, args, options);
482
+ return true;
483
+ } catch (cause) {
484
+ if (cause instanceof WorkspaceProcessCleanupError || cause instanceof Error && "reportCleanup" in cause) throw cause;
485
+ operation.signal.throwIfAborted();
486
+ await removeTemporaryEntryAsync(to);
487
+ return false;
488
+ }
489
+ };
490
+ const directoryClone = (await lstat(from)).isDirectory() ? await clonefile() : null;
491
+ if (!(directoryClone && await copiedWith(directoryClone, [from, to])) && !await copiedWith("cp", [
492
+ "-Rc",
493
+ from,
494
+ to
495
+ ])) {
406
496
  await getExecutor().runFileAsync("cp", [
407
497
  "-R",
408
498
  from,
@@ -410,7 +500,7 @@ async function cloneIgnoredEntries({ root, target, patterns, operation }) {
410
500
  ], options);
411
501
  cloned = false;
412
502
  }
413
- if ((await lstat(to)).isDirectory()) await removeCopiedExclusionsAsync(to, rel, operation.signal);
503
+ if ((await lstat(to)).isDirectory()) await removeKnownCopiedPaths(to, rel, operation.signal);
414
504
  copied.push(rel);
415
505
  } catch (cause) {
416
506
  if (cause instanceof WorkspaceProcessCleanupError || cause instanceof Error && "reportCleanup" in cause) throw cause;
@@ -1296,6 +1386,9 @@ function iosSimSlimProfileSetting(settings, settingsRoot) {
1296
1386
  throw new Error(`Could not read ios.simslimProfile ${value}: ${String(error?.message || error)}`, { cause: error });
1297
1387
  }
1298
1388
  }
1389
+ function iosSimSlimDefaultSetting(settings) {
1390
+ return isPlainObject(settings) && isPlainObject(settings.ios) && settings.ios.simslim === "on";
1391
+ }
1299
1392
  function iosString(settings, key) {
1300
1393
  if (!isPlainObject(settings) || !isPlainObject(settings.ios)) return void 0;
1301
1394
  return settings.ios[key];
@@ -1649,4 +1742,4 @@ function webSettings(settings) {
1649
1742
  };
1650
1743
  }
1651
1744
  //#endregion
1652
- export { settingOriginScope as $, metroIdleStopMinutesSetting as A, readWorktreeExclude as At, realpathInside as B, warmWorktreePaths as Bt, iosSigningIdentitySha1Setting as C, isPodInstallChurn as Ct, mergeSettingsLayers as D, locallyKnownUpstream as Dt, maintenanceKeepSetting as E, listWorktreesAsync as Et, parseIosRemote as F, resolveFullRefAsync as Ft, resolveCacheProviderConfig as G, temporaryRoot as Gt, remoteEasFallbackSetting as H, makeTemporaryDirectory as Ht, projectSettingsContext as I, resolveSourceCheckoutAsync as It, resolveProjectSettingsAsync as J, resolveIosProjectDir as K, projectSettingsContextAsync as L, restoreFileAsync as Lt, metroTunnelSettingError as M, repoRoot as Mt, metroWarmupUrlSetting as N, repoRootAsync as Nt, metroCommandSetting as O, locallyKnownUpstreamAsync as Ot, ngrokUrlSetting as P, resolveFullRef as Pt, settingOrigin as Q, publicUrlSetting as R, sourceCheckoutOf as Rt, iosSigningIdentitySettingError as S, hasUncommittedWorkAsync as St, iosSimSlimProfileSetting as T, listWorktrees as Tt, remoteIosSetting as U, removeTemporaryEntry as Ut, remoteAndroidSetting as V, filesystemDevice as Vt, resolveAndroidLayout as W, removeTemporaryEntryAsync as Wt, runnableMetroCommand as X, resolveSettings as Y, settingFile as Z, iosLanHostSetting as _, gitCommonDir as _t, SETTING_SHAPE_REMEDY as a, webSettings as at, iosProjectDirSettingError as b, hasPopulatedSubmodulesAsync as bt, androidDataPartitionSizeBytes as c, detectProviders as ct, androidLayoutSetting as d, branchExistsAsync as dt, settingShapeErrors as et, androidLayoutSettingError as f, cloneIgnoredEntries as ft, deviceReclaimIdleMinutesSetting as g, dirtyPathsAsync as gt, deviceIdleShutdownMinutesSetting as h, dirtyFingerprintFiles as ht, SETTINGS_WITH_RESOLVE_TIME_FALLBACK as i, unknownSettingKeys as it, metroPortSetting as j, removeWorktreeAsync as jt, metroCommandSettingError as k, podsOutOfSync as kt, androidDataPartitionSizeGbSetting as l, planMetroReach as lt, defaultAndroidLayout as m, depsOutOfSync as mt, METRO_COMMAND_PORT as n, settingsLayers as nt, androidAvdConfigSetting as o, workspaceHiddenSetting as ot, cacheProviderSettingError as p, deleteBranchAsync as pt, resolveProjectSettings as q, PATH_SETTINGS as r, tunnelModeSetting as rt, androidAvdConfigSettingError as s, PUBLIC_METRO_ENV as st, ANDROID_AVD_CONFIG_HELP as t, settingValueAt as tt, androidDataPartitionSizeGbSettingError as u, resolveTailscaleBinary as ut, iosLanHostSettingError as v, gitCommonDirAsync as vt, iosSigningIdentitySha1SettingError as w, linkedWorktreesOnDisk as wt, iosSigningIdentitySetting as x, hasRemoteAsync as xt, iosProjectDirSetting as y, gitCommonDirOnDisk as yt, readCommittedSettings as z, unpushedCommitsAsync as zt };
1745
+ export { settingOrigin as $, metroCommandSettingError as A, podsOutOfSync as At, readCommittedSettings as B, unpushedCommitsAsync as Bt, iosSigningIdentitySha1Setting as C, hasUncommittedWorkAsync as Ct, maintenanceKeepSetting as D, listWorktreesAsync as Dt, iosSimSlimProfileSetting as E, listWorktrees as Et, ngrokUrlSetting as F, resolveFullRef as Ft, resolveAndroidLayout as G, removeTemporaryEntryAsync as Gt, remoteAndroidSetting as H, filesystemDevice as Ht, parseIosRemote as I, resolveFullRefAsync as It, resolveProjectSettings as J, resolveCacheProviderConfig as K, temporaryRoot as Kt, projectSettingsContext as L, resolveSourceCheckoutAsync as Lt, metroPortSetting as M, removeWorktreeAsync as Mt, metroTunnelSettingError as N, repoRoot as Nt, mergeSettingsLayers as O, locallyKnownUpstream as Ot, metroWarmupUrlSetting as P, repoRootAsync as Pt, settingFile as Q, projectSettingsContextAsync as R, restoreFileAsync as Rt, iosSigningIdentitySettingError as S, hasRemoteAsync as St, iosSimSlimDefaultSetting as T, linkedWorktreesOnDisk as Tt, remoteEasFallbackSetting as U, makeTemporaryDirectory as Ut, realpathInside as V, warmWorktreePaths as Vt, remoteIosSetting as W, removeTemporaryEntry as Wt, resolveSettings as X, resolveProjectSettingsAsync as Y, runnableMetroCommand as Z, iosLanHostSetting as _, dirtyPathsAsync as _t, SETTING_SHAPE_REMEDY as a, unknownSettingKeys as at, iosProjectDirSettingError as b, gitCommonDirOnDisk as bt, androidDataPartitionSizeBytes as c, PUBLIC_METRO_ENV as ct, androidLayoutSetting as d, resolveTailscaleBinary as dt, settingOriginScope as et, androidLayoutSettingError as f, branchExistsAsync as ft, deviceReclaimIdleMinutesSetting as g, dirtyFingerprintFiles as gt, deviceIdleShutdownMinutesSetting as h, depsOutOfSync as ht, SETTINGS_WITH_RESOLVE_TIME_FALLBACK as i, tunnelModeSetting as it, metroIdleStopMinutesSetting as j, readWorktreeExclude as jt, metroCommandSetting as k, locallyKnownUpstreamAsync as kt, androidDataPartitionSizeGbSetting as l, detectProviders as lt, defaultAndroidLayout as m, deleteBranchAsync as mt, METRO_COMMAND_PORT as n, settingValueAt as nt, androidAvdConfigSetting as o, webSettings as ot, cacheProviderSettingError as p, cloneIgnoredEntries as pt, resolveIosProjectDir as q, PATH_SETTINGS as r, settingsLayers as rt, androidAvdConfigSettingError as s, workspaceHiddenSetting as st, ANDROID_AVD_CONFIG_HELP as t, settingShapeErrors as tt, androidDataPartitionSizeGbSettingError as u, planMetroReach as ut, iosLanHostSettingError as v, gitCommonDir as vt, iosSigningIdentitySha1SettingError as w, isPodInstallChurn as wt, iosSigningIdentitySetting as x, hasPopulatedSubmodulesAsync as xt, iosProjectDirSetting as y, gitCommonDirAsync as yt, publicUrlSetting as z, sourceCheckoutOf as zt };
@@ -1,4 +1,4 @@
1
- import { a as layerFile, c as settingEntry, i as SettingsRefusal, n as readScope, o as readSettingsContext, r as requireSetting, s as readSettingsPayload, t as mutateSetting } from "./settings-write-Chuy7Cte.mjs";
1
+ import { a as layerFile, c as settingEntry, i as SettingsRefusal, n as readScope, o as readSettingsContext, r as requireSetting, s as readSettingsPayload, t as mutateSetting } from "./settings-write-n0zwfohx.mjs";
2
2
  import { SETTING_SCOPES } from "@stim-cli/core/state";
3
3
  import chalk from "chalk";
4
4
  //#region src/commands/settings.ts
@@ -1,10 +1,10 @@
1
- import { i as withWorkspaceProcessLock } from "./exec-DEoAhcze.mjs";
2
- import { A as writeConfigSettingAsync, O as withConfigLockAsync$1, _ as loadConfig$1, f as getConfigPath$1, h as getRepoSettings, m as getProjectSettings } from "./config-DlrsduwG.mjs";
3
- import { a as killOnAbort, i as gitPath } from "./operation-exec-BW0em61G.mjs";
4
- import { it as unknownSettingKeys, z as readCommittedSettings } from "./settings-C7O8A6ZI.mjs";
5
- import { r as findCommandWorkspaceAsync, t as NO_PROJECT_REFUSAL } from "./project-DhCtQWWU.mjs";
6
- import { i as stimDesktopInstalledAsync, n as settingDefault, r as stimDesktopInstalled } from "./stim-desktop-D5OGpYZM.mjs";
7
- import { n as recordingLayers, t as deleteTurnedOffRecordings } from "./recordings-CQmfzAh7.mjs";
1
+ import { u as withWorkspaceProcessLock } from "./exec-VFRpu1iA.mjs";
2
+ import { A as writeConfigSettingAsync, O as withConfigLockAsync$1, _ as loadConfig$1, f as getConfigPath$1, h as getRepoSettings, m as getProjectSettings } from "./config-BZhXY15H.mjs";
3
+ import { a as killOnAbort, i as gitPath } from "./operation-exec-CUZifp6Z.mjs";
4
+ import { B as readCommittedSettings, at as unknownSettingKeys } from "./settings-B5tCoq9N.mjs";
5
+ import { r as findCommandWorkspaceAsync, t as NO_PROJECT_REFUSAL } from "./project-BiC68mIp.mjs";
6
+ import { i as stimDesktopInstalledAsync, n as settingDefault, r as stimDesktopInstalled } from "./stim-desktop-DS0mzR8U.mjs";
7
+ import { n as recordingLayers, t as deleteTurnedOffRecordings } from "./recordings-BaoQ0t-J.mjs";
8
8
  import { existsSync, readFileSync, renameSync, unlinkSync, writeFileSync } from "node:fs";
9
9
  import { join } from "node:path";
10
10
  import { configDir } from "@stim-cli/core";
@@ -315,6 +315,25 @@
315
315
  "relative": true
316
316
  }
317
317
  },
318
+ "simslim": {
319
+ "description": "Slim every Stim-owned iOS simulator with SimSlim's default categories when no ios.simslimProfile is set; off in a project opts that app out",
320
+ "type": "string",
321
+ "enum": [
322
+ "on",
323
+ "off"
324
+ ],
325
+ "default": "off",
326
+ "x-stim": {
327
+ "key": "ios.simslim",
328
+ "kind": "choice",
329
+ "scopes": [
330
+ "machine",
331
+ "workspace",
332
+ "repo",
333
+ "committed"
334
+ ]
335
+ }
336
+ },
318
337
  "simslimProfile": {
319
338
  "description": "SimSlim JSON profile under the app",
320
339
  "type": "string",
@@ -1283,6 +1302,25 @@
1283
1302
  ]
1284
1303
  }
1285
1304
  },
1305
+ "simslim": {
1306
+ "description": "Slim every Stim-owned iOS simulator with SimSlim's default categories when no ios.simslimProfile is set; off in a project opts that app out",
1307
+ "type": "string",
1308
+ "enum": [
1309
+ "on",
1310
+ "off"
1311
+ ],
1312
+ "default": "off",
1313
+ "x-stim": {
1314
+ "key": "ios.simslim",
1315
+ "kind": "choice",
1316
+ "scopes": [
1317
+ "machine",
1318
+ "workspace",
1319
+ "repo",
1320
+ "committed"
1321
+ ]
1322
+ }
1323
+ },
1286
1324
  "appStoreConnectKeyPath": {
1287
1325
  "description": "App Store Connect API key (.p8) that `stim device provision ios` authenticates with",
1288
1326
  "type": "string",
@@ -2361,6 +2399,19 @@
2361
2399
  ]
2362
2400
  }
2363
2401
  },
2402
+ "easMaxDurationMinutes": {
2403
+ "description": "Maximum minutes of each EAS Simulator session Stim creates, after which EAS stops it and stops billing; stim stop and gc --delete end a session sooner. EAS rejects a value above the account plan's session limit",
2404
+ "type": "integer",
2405
+ "minimum": 1,
2406
+ "default": 30,
2407
+ "x-stim": {
2408
+ "key": "remote.easMaxDurationMinutes",
2409
+ "kind": "number",
2410
+ "scopes": [
2411
+ "machine"
2412
+ ]
2413
+ }
2414
+ },
2364
2415
  "build": {
2365
2416
  "description": "Build placement: auto follows remote.buildMode within enabled automatic pool members; local always builds here; a name in remote.machines requires that remote machine without fallback. The ios, android and macos --remote-build flag overrides this setting and its environment override",
2366
2417
  "type": "string",
@@ -1,20 +1,35 @@
1
- import { g as process_identity_exports, m as operationState, p as isTermination, t as getExecutor, x as ownership_claim_exports } from "./exec-DEoAhcze.mjs";
2
- import { d as getConfigDir } from "./config-DlrsduwG.mjs";
1
+ import { D as ownership_claim_exports, S as process_identity_exports, b as operationState, t as getExecutor, y as isTermination } from "./exec-VFRpu1iA.mjs";
2
+ import { d as getConfigDir } from "./config-BZhXY15H.mjs";
3
3
  import { n as stripAnsi, r as waitForChild, t as createLineReader } from "./process-output-Fpl8PYi8.mjs";
4
4
  import { join } from "node:path";
5
5
  //#region src/engine/simslim.ts
6
- async function reconcileSimSlim({ udid, profile, previouslyManaged = false, out = () => {}, spawn, timeoutMs = 72e4, cleanupMs = 1e4, context }) {
7
- if (!profile && !previouslyManaged) return {
6
+ async function reconcileSimSlim(options) {
7
+ try {
8
+ return await applySimSlim(options);
9
+ } catch (error) {
10
+ const cause = error instanceof Error ? error.cause : void 0;
11
+ const missing = cause instanceof Error && "code" in cause && cause.code === "ENOENT";
12
+ if (options.profile || !options.slimByDefault || !missing) throw error;
13
+ options.out?.("SimSlim: ios.simslim is on but the `simslim` command is not installed; continuing without it. Run `brew install mobai-app/tap/simslim`.");
14
+ return {
15
+ managed: Boolean(options.previouslyManaged),
16
+ profile: null
17
+ };
18
+ }
19
+ }
20
+ async function applySimSlim({ udid, profile, slimByDefault = false, previouslyManaged = false, out = () => {}, spawn, timeoutMs = 72e4, cleanupMs = 1e4, context }) {
21
+ if (!profile && !slimByDefault && !previouslyManaged) return {
8
22
  managed: false,
9
23
  profile: null
10
24
  };
11
- const action = profile ? "on" : "off";
25
+ const slim = Boolean(profile) || slimByDefault;
26
+ const action = slim ? "on" : "off";
12
27
  const args = profile ? [
13
28
  "on",
14
29
  udid,
15
30
  "--profile",
16
31
  profile
17
- ] : ["off", udid];
32
+ ] : slim ? ["on", udid] : ["off", udid];
18
33
  const lines = [];
19
34
  const onLine = (raw) => {
20
35
  const line = stripAnsi(raw).trim();
@@ -130,7 +145,7 @@ async function reconcileSimSlim({ udid, profile, previouslyManaged = false, out
130
145
  throw new Error(`SimSlim ${action} failed with exit code ${result?.code ?? "unknown"}.${detail}`);
131
146
  }
132
147
  return {
133
- managed: Boolean(profile),
148
+ managed: slim,
134
149
  profile: profile ?? null
135
150
  };
136
151
  }
@@ -1,9 +1,9 @@
1
- import { G as projectDeviceSlots, U as parseDeviceSlotKey, p as getProject } from "./config-DlrsduwG.mjs";
2
- import { r as readWorkspaceState$1 } from "./workspace-state-U08dEzhG.mjs";
3
- import { gn as deviceShellArg } from "./budget-3ivAK99e.mjs";
4
- import { y as fileLeaseIo } from "./activity-BpWUPgUm.mjs";
5
- import { O as getAvdNameForSerialAsync, j as listAdbDevicesAsync } from "./android-C7sVmyI9.mjs";
6
- import { f as listAllIosSimsAsync } from "./ios-hcBpnEGk.mjs";
1
+ import { G as projectDeviceSlots, U as parseDeviceSlotKey, p as getProject } from "./config-BZhXY15H.mjs";
2
+ import { r as readWorkspaceState$1 } from "./workspace-state-CPSp3mav.mjs";
3
+ import { O as getAvdNameForSerialAsync, j as listAdbDevicesAsync } from "./android-Cjcj8MCw.mjs";
4
+ import { yn as deviceShellArg } from "./budget-HyShrIpL.mjs";
5
+ import { y as fileLeaseIo } from "./activity-BpjwrQXU.mjs";
6
+ import { f as listAllIosSimsAsync } from "./ios-BQzvJlzw.mjs";
7
7
  import { hostedNativeRecords } from "@stim-cli/core/state";
8
8
  //#region src/engine/slot-launch.ts
9
9
  function launchSlotScope(root, slot = "default") {
@@ -1,6 +1,5 @@
1
- import { h as withDrainingCancellation, t as getExecutor } from "./exec-DEoAhcze.mjs";
2
- import { f as throwIfCancelled } from "./operation-exec-BW0em61G.mjs";
3
- import { d as runCancellationSignal } from "./native-run-Dv88i0aU.mjs";
1
+ import { c as throwIfCancelled, t as getExecutor, x as withDrainingCancellation } from "./exec-VFRpu1iA.mjs";
2
+ import { d as runCancellationSignal } from "./native-run-D5OJsGwA.mjs";
4
3
  import { existsSync, lstatSync, promises, readdirSync, realpathSync, statSync } from "node:fs";
5
4
  import { dirname, isAbsolute, join, relative, resolve, sep } from "node:path";
6
5
  import { validMacosResourceDestination } from "@stim-cli/core";
@@ -1,2 +1,2 @@
1
- import { a as registerStart, c as startDevServer, d as supervisorSignalable, f as tailLines, i as readLogTail, l as startFacts, n as liveSupervisor, o as resolveWorkspaceMetroPort, p as wantsExpoOwnTunnel, r as parseWait, s as startCommand, t as failureEvidence, u as supervisorEntry } from "./start-CU8mCPC7.mjs";
1
+ import { a as registerStart, c as startDevServer, d as supervisorSignalable, f as tailLines, i as readLogTail, l as startFacts, n as liveSupervisor, o as resolveWorkspaceMetroPort, p as wantsExpoOwnTunnel, r as parseWait, s as startCommand, t as failureEvidence, u as supervisorEntry } from "./start-YMpNwLhh.mjs";
2
2
  export { startCommand as default, failureEvidence, liveSupervisor, parseWait, readLogTail, registerStart, resolveWorkspaceMetroPort, startDevServer, startFacts, supervisorEntry, supervisorSignalable, tailLines, wantsExpoOwnTunnel };