rnxsim 0.1.345 → 0.1.347

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 +9 -3
  2. package/cli/commands/welcome.ts +19 -17
  3. package/cli/outbound-endpoints.ts +1 -1
  4. package/dist-cli/bin.js +5 -5
  5. package/dist-cli/chunks/{agent-52G55XTO.js → agent-VVY2A5YV.js} +2 -2
  6. package/dist-cli/chunks/{agent-wrapper-BOZM43ON.js → agent-wrapper-YBMTZ3KU.js} +2 -2
  7. package/dist-cli/chunks/{app-fonts-A2L6V5EZ.js → app-fonts-EF7FM3VP.js} +2 -2
  8. package/dist-cli/chunks/{assert-CJKIP4LN.js → assert-J7N6WGMS.js} +2 -2
  9. package/dist-cli/chunks/{auth-VHHN3TOB.js → auth-YGX3WVEL.js} +2 -2
  10. package/dist-cli/chunks/{beta-EBDIGV3E.js → beta-JXYFAOHO.js} +2 -2
  11. package/dist-cli/chunks/{camera-5F4KKCQ3.js → camera-WIVF3UQ3.js} +2 -2
  12. package/dist-cli/chunks/{chunk-PLB6UVVX.js → chunk-23WNLQUB.js} +2 -2
  13. package/dist-cli/chunks/{chunk-KZFJNDH3.js → chunk-24Q4J4U6.js} +1 -1
  14. package/dist-cli/chunks/chunk-2E5KDIGN.js +14 -0
  15. package/dist-cli/chunks/{chunk-XJBFJGNT.js → chunk-2PAG4FBP.js} +2 -2
  16. package/dist-cli/chunks/{chunk-7LGINKM6.js → chunk-2UZ6QQ6S.js} +2 -2
  17. package/dist-cli/chunks/{chunk-7V4KPZ7O.js → chunk-2W4ME6YI.js} +2 -2
  18. package/dist-cli/chunks/{chunk-5GXRRUOA.js → chunk-3HBHHU5F.js} +3 -3
  19. package/dist-cli/chunks/{chunk-E2RGSCHT.js → chunk-3SPBSEVL.js} +1 -1
  20. package/dist-cli/chunks/{chunk-QNBBKRCA.js → chunk-4KK5IRA6.js} +2 -2
  21. package/dist-cli/chunks/{chunk-4OKV7T5D.js → chunk-4KOWLH77.js} +2 -2
  22. package/dist-cli/chunks/{chunk-DPP2M4AJ.js → chunk-4RI6KXVH.js} +1 -1
  23. package/dist-cli/chunks/{chunk-DHM3JDCK.js → chunk-6CGQWXXT.js} +2 -2
  24. package/dist-cli/chunks/{chunk-ZMTZ5G5H.js → chunk-7C6XE6AT.js} +2 -2
  25. package/dist-cli/chunks/{chunk-7YMQRA6L.js → chunk-7D56NCJ3.js} +2 -2
  26. package/dist-cli/chunks/{chunk-4ZILDTZX.js → chunk-ABBCVE5V.js} +2 -2
  27. package/dist-cli/chunks/{chunk-JC33TOAF.js → chunk-ANANQDHB.js} +1 -1
  28. package/dist-cli/chunks/{chunk-BFTDL2GX.js → chunk-BA45ZZKU.js} +2 -2
  29. package/dist-cli/chunks/{chunk-RB4VFUNM.js → chunk-BAXXUHKV.js} +2 -2
  30. package/dist-cli/chunks/{chunk-LAQGSSTT.js → chunk-DC4MQAR3.js} +1 -1
  31. package/dist-cli/chunks/{chunk-KA4PJNTE.js → chunk-DTNRKFSE.js} +2 -2
  32. package/dist-cli/chunks/{chunk-A2Q76LJV.js → chunk-EEZEVA2C.js} +2 -2
  33. package/dist-cli/chunks/{chunk-7UIIAHVU.js → chunk-EIIZZ2XK.js} +2 -2
  34. package/dist-cli/chunks/{chunk-TEU5NGUA.js → chunk-FQ3OHHCY.js} +2 -2
  35. package/dist-cli/chunks/{chunk-BCQV63BW.js → chunk-HWAGFGV7.js} +3 -3
  36. package/dist-cli/chunks/{chunk-XXZLK4BY.js → chunk-HY7XOD5E.js} +1 -1
  37. package/dist-cli/chunks/{chunk-T7SBFG5I.js → chunk-IQWQ6KI7.js} +2 -2
  38. package/dist-cli/chunks/{chunk-TMRD5MHL.js → chunk-IS2LT6MN.js} +2 -2
  39. package/dist-cli/chunks/{chunk-NUPRHZQW.js → chunk-JG2TIZ7E.js} +2 -2
  40. package/dist-cli/chunks/{chunk-YVSUFVVB.js → chunk-JKRVWCTC.js} +1 -1
  41. package/dist-cli/chunks/{chunk-3DBTS4MC.js → chunk-JP4FCK5J.js} +6 -6
  42. package/dist-cli/chunks/{chunk-RTDHX6CW.js → chunk-JQTBZERT.js} +2 -2
  43. package/dist-cli/chunks/{chunk-OPHT4DUO.js → chunk-KYTBJ2QV.js} +1 -1
  44. package/dist-cli/chunks/{chunk-63ASUHOV.js → chunk-LRRQI4TP.js} +2 -2
  45. package/dist-cli/chunks/{chunk-RT3DXTDP.js → chunk-LWE2HRS4.js} +2 -2
  46. package/dist-cli/chunks/{chunk-U5YHXQHH.js → chunk-NJ2JVAGV.js} +2 -2
  47. package/dist-cli/chunks/{chunk-4BIPA7MD.js → chunk-O7WPHIYQ.js} +1 -1
  48. package/dist-cli/chunks/{chunk-WPPGU5IK.js → chunk-OG3KGU4V.js} +2 -2
  49. package/dist-cli/chunks/{chunk-KH777UAO.js → chunk-PCU2CQCI.js} +3 -3
  50. package/dist-cli/chunks/{chunk-KRZPFXVN.js → chunk-QJYUHYQS.js} +1 -1
  51. package/dist-cli/chunks/{chunk-HK7YKH6N.js → chunk-QK2U5IW3.js} +2 -2
  52. package/dist-cli/chunks/{chunk-3N7M5HMJ.js → chunk-SMLCC5EP.js} +1 -1
  53. package/dist-cli/chunks/{chunk-QNRWPAOA.js → chunk-SNBSRIKO.js} +2 -2
  54. package/dist-cli/chunks/{chunk-R7ZNRGQN.js → chunk-SYQZTZTR.js} +1 -1
  55. package/dist-cli/chunks/{chunk-7GO2DSYQ.js → chunk-TAYE2YII.js} +1 -1
  56. package/dist-cli/chunks/{chunk-EPLVIDPC.js → chunk-U6CJ3EHB.js} +1 -1
  57. package/dist-cli/chunks/{chunk-GKGXULJK.js → chunk-UM7IG4DE.js} +2 -2
  58. package/dist-cli/chunks/{chunk-VLBN3KRC.js → chunk-VENH5KLL.js} +1 -1
  59. package/dist-cli/chunks/{chunk-P2CGGMU2.js → chunk-W4MASUQ7.js} +2 -2
  60. package/dist-cli/chunks/{chunk-WU72KL6Z.js → chunk-WIYBEKBM.js} +2 -2
  61. package/dist-cli/chunks/{chunk-LRM2XCEQ.js → chunk-WNZOJDBL.js} +1 -1
  62. package/dist-cli/chunks/{chunk-UVOEHIGP.js → chunk-XB7DLZNQ.js} +1 -1
  63. package/dist-cli/chunks/{chunk-PLUWN2V5.js → chunk-XGUCAKZM.js} +1 -1
  64. package/dist-cli/chunks/{chunk-DGTV3KOW.js → chunk-Z6K6TD7X.js} +1 -1
  65. package/dist-cli/chunks/{chunk-BHKSCNDC.js → chunk-ZPCQFQEN.js} +1 -1
  66. package/dist-cli/chunks/{chunk-HXE344V3.js → chunk-ZY44NCRQ.js} +1 -1
  67. package/dist-cli/chunks/{cleanup-MAVZJXVW.js → cleanup-ZIDQQLEN.js} +2 -2
  68. package/dist-cli/chunks/cli-version-BEJJXF35.js +4 -0
  69. package/dist-cli/chunks/{compat-7AURLGCS.js → compat-5PFPTBBK.js} +2 -2
  70. package/dist-cli/chunks/{config-TN3Y4J5N.js → config-CG73FOTM.js} +2 -2
  71. package/dist-cli/chunks/{control-EV2ELU5R.js → control-7IYIDOOI.js} +2 -2
  72. package/dist-cli/chunks/daemon-G6VR7LJI.js +4 -0
  73. package/dist-cli/chunks/{debug-JICITUB6.js → debug-6AQQXXE3.js} +3 -3
  74. package/dist-cli/chunks/{desktop-4F5HGLLX.js → desktop-HJE5B4XO.js} +3 -3
  75. package/dist-cli/chunks/{detox-ZC7NHLJI.js → detox-KUZ7EYOP.js} +2 -2
  76. package/dist-cli/chunks/{device-V57GHRXX.js → device-O6WI4PQT.js} +2 -2
  77. package/dist-cli/chunks/{diagnose-FF4IWYXC.js → diagnose-FTCJGH2Q.js} +2 -2
  78. package/dist-cli/chunks/{disk-cleanup-T277L6ZO.js → disk-cleanup-YAXG52EZ.js} +2 -2
  79. package/dist-cli/chunks/drivers-6QOL2SON.js +4 -0
  80. package/dist-cli/chunks/{film-G7ZAPWB7.js → film-KTLKRCJR.js} +3 -3
  81. package/dist-cli/chunks/flow-6VQN4VNW.js +4 -0
  82. package/dist-cli/chunks/help-22OURA2E.js +4 -0
  83. package/dist-cli/chunks/{hidden-runtime-alias-VSJNNSNI.js → hidden-runtime-alias-W375XBOM.js} +2 -2
  84. package/dist-cli/chunks/{home-paths-75HP3HKA.js → home-paths-CIGRWLDB.js} +2 -2
  85. package/dist-cli/chunks/inspect-36A2IEJL.js +4 -0
  86. package/dist-cli/chunks/install-desktop-KOW3XXUF.js +4 -0
  87. package/dist-cli/chunks/{login-ZSIHGHUK.js → login-AJWLXLPQ.js} +2 -2
  88. package/dist-cli/chunks/{logout-Q4DXMI2C.js → logout-CEJLZIOI.js} +2 -2
  89. package/dist-cli/chunks/{maestro-LE5LCRBL.js → maestro-YF4M6M6L.js} +3 -3
  90. package/dist-cli/chunks/{maestro-generate-D3ZIJCRL.js → maestro-generate-FJWDLMEB.js} +3 -3
  91. package/dist-cli/chunks/{mode-BWX6MDPJ.js → mode-6BJ523BY.js} +2 -2
  92. package/dist-cli/chunks/{optional-demo-registry-6CVASL3S.js → optional-demo-registry-5CKCN2TP.js} +2 -2
  93. package/dist-cli/chunks/{perf-NXQZISN6.js → perf-WE6QTFJU.js} +2 -2
  94. package/dist-cli/chunks/{permissions-5PD67RRO.js → permissions-OZZZZFPB.js} +2 -2
  95. package/dist-cli/chunks/privacy-3BERNBUM.js +4 -0
  96. package/dist-cli/chunks/{record-YJF4KXMR.js → record-QHQS2524.js} +3 -3
  97. package/dist-cli/chunks/{report-issue-XOL5FQBG.js → report-issue-SEMVVJUH.js} +2 -2
  98. package/dist-cli/chunks/reset-A5AA5ML6.js +4 -0
  99. package/dist-cli/chunks/runtime-R26QWA2M.js +4 -0
  100. package/dist-cli/chunks/{screenshot-command-VRPJXWFS.js → screenshot-command-WW33MAB3.js} +3 -3
  101. package/dist-cli/chunks/{screenshot-layers-QP4WA2F5.js → screenshot-layers-2GJTEQ4T.js} +2 -2
  102. package/dist-cli/chunks/{screenshots-capture-O2IBAVSP.js → screenshots-capture-J5HKONCC.js} +2 -2
  103. package/dist-cli/chunks/{serve-WC6RZNJL.js → serve-FEBNDKUD.js} +2 -2
  104. package/dist-cli/chunks/{setup-A6BIG3KL.js → setup-NGZWS373.js} +2 -2
  105. package/dist-cli/chunks/{skills-A7YC6RL5.js → skills-CFCZFEME.js} +2 -2
  106. package/dist-cli/chunks/{state-IJI5YROJ.js → state-XWRKK7FW.js} +2 -2
  107. package/dist-cli/chunks/{storage-Z2DBO2PQ.js → storage-C5GNK4XB.js} +2 -2
  108. package/dist-cli/chunks/store-L3A4CLND.js +4 -0
  109. package/dist-cli/chunks/telemetry-O67J22QU.js +4 -0
  110. package/dist-cli/chunks/{timeline-N7V2M6QA.js → timeline-7RA7ZILQ.js} +2 -2
  111. package/dist-cli/chunks/{upgrade-P2NH3BOR.js → upgrade-ZW6IJ5LX.js} +2 -2
  112. package/dist-cli/chunks/upload-UKUN6HCD.js +4 -0
  113. package/dist-cli/chunks/{version-OUHCSCUS.js → version-N3E4OIMM.js} +2 -2
  114. package/dist-cli/chunks/{web-6NRTF3UV.js → web-UC2SFEBA.js} +2 -2
  115. package/dist-cli/chunks/welcome-DAZPCMES.js +5 -0
  116. package/dist-cli/chunks/{what-happened-FUEL3BEF.js → what-happened-VUNKID5W.js} +2 -2
  117. package/dist-lib/agent-daemon-client.cjs +1 -1
  118. package/dist-lib/agent-events.cjs +1 -1
  119. package/dist-lib/agent-identity.cjs +1 -1
  120. package/dist-lib/agent-sessions.cjs +1 -1
  121. package/dist-lib/attached-projects.cjs +1 -1
  122. package/dist-lib/auth/shared-session.cjs +1 -1
  123. package/dist-lib/backend-origin.cjs +13 -1
  124. package/dist-lib/beta.cjs +1 -1
  125. package/dist-lib/beta.mjs +1 -1
  126. package/dist-lib/bridge-constants.cjs +1 -1
  127. package/dist-lib/bridge-contract.cjs +1 -1
  128. package/dist-lib/cli-constants.cjs +1 -1
  129. package/dist-lib/config.cjs +1 -1
  130. package/dist-lib/detox/index.cjs +1 -1
  131. package/dist-lib/dev-bundle-resolution.cjs +26 -10
  132. package/dist-lib/home-paths.cjs +1 -1
  133. package/dist-lib/host/bridge-host.cjs +101 -58
  134. package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
  135. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  136. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  137. package/dist-lib/host/replacement-module-handler.cjs +1 -1
  138. package/dist-lib/host/websocket-proxy.cjs +1 -1
  139. package/dist-lib/index.cjs +1 -1
  140. package/dist-lib/jump-to-source-babel.cjs +1 -1
  141. package/dist-lib/menu.cjs +1 -1
  142. package/dist-lib/menu.mjs +1 -1
  143. package/dist-lib/metro-production-bundle.cjs +1 -1
  144. package/dist-lib/metro-production-bundle.mjs +1 -1
  145. package/dist-lib/metro.cjs +1 -1
  146. package/dist-lib/profiles.cjs +1 -1
  147. package/dist-lib/public-brand.cjs +1 -1
  148. package/dist-lib/react-native-host-modules.cjs +1 -1
  149. package/dist-lib/react-native-host-modules.mjs +1 -1
  150. package/dist-lib/render-mode.cjs +1 -1
  151. package/dist-lib/scripts/dev-server-scanner.cjs +106 -59
  152. package/dist-lib/sdk.cjs +1 -1
  153. package/dist-lib/sdk.mjs +1 -1
  154. package/dist-lib/skills.cjs +127 -72
  155. package/dist-lib/vite.cjs +1 -1
  156. package/package.json +1 -1
  157. package/scripts/dev-server-scanner.ts +101 -47
  158. package/src/backend-origin.ts +15 -1
  159. package/src/dev-bundle-resolution.ts +29 -12
  160. package/dist-cli/chunks/chunk-TOF5TA5X.js +0 -14
  161. package/dist-cli/chunks/cli-version-2B4KRNML.js +0 -4
  162. package/dist-cli/chunks/daemon-KKDG5MYR.js +0 -4
  163. package/dist-cli/chunks/drivers-LCX7S76X.js +0 -4
  164. package/dist-cli/chunks/flow-ONZGGFGD.js +0 -4
  165. package/dist-cli/chunks/help-DROVDXJM.js +0 -4
  166. package/dist-cli/chunks/inspect-MDA7ESGQ.js +0 -4
  167. package/dist-cli/chunks/install-desktop-EIVZHIFA.js +0 -4
  168. package/dist-cli/chunks/privacy-H5KNRNIZ.js +0 -4
  169. package/dist-cli/chunks/reset-5LZN5P5B.js +0 -4
  170. package/dist-cli/chunks/runtime-U36VWBH3.js +0 -4
  171. package/dist-cli/chunks/store-BYTCKNIC.js +0 -4
  172. package/dist-cli/chunks/telemetry-JLHFMD7N.js +0 -4
  173. package/dist-cli/chunks/upload-Z2WX5DCD.js +0 -4
  174. package/dist-cli/chunks/welcome-6RS7PEJW.js +0 -5
package/README.md CHANGED
@@ -207,7 +207,8 @@ rnx open /settings # dispatch a React Native deep link into that app
207
207
  Start Metro, Expo, One, or another supported React Native development server
208
208
  the way you normally do, then run `npx rnxsim` from any directory. If one app is
209
209
  running, rnx opens it immediately. If several are running, a human terminal gets
210
- one short choice; CI and agents choose deterministically and never prompt.
210
+ one short choice. CI and agents refuse to guess and print one explicit
211
+ `rnx open <port>` command for each discovered app.
211
212
 
212
213
  The first `rnx open` launches an isolated Chrome for Testing sim. The CLI
213
214
  resolves Playwright from the app or CLI install, asks that exact package for
@@ -345,8 +346,13 @@ module.exports = withRNX(config, { open: { appName: 'My App' } })
345
346
  The `open` option serves the RNX shell and opens the app in its own named
346
347
  Electron window. `open: true` derives the name from `package.json`; use the
347
348
  object form when the display name differs. Run `rnx desktop install` once before
348
- enabling it. `SOOTSIM_NO_OPEN=1` keeps the server headless. The Metro wrapper
349
- also has two independent non-window opt-ins.
349
+ enabling it. The macOS desktop download is about 109 MiB and the installed app
350
+ uses about 267 MiB, so the browser remains the recommended first-run path and
351
+ Electron is an opt-in desktop upgrade. The notarized CLI install did not produce
352
+ a Gatekeeper prompt on a clean profile. A Mac that previously ran an unsigned
353
+ development Electron build against the same user-data directory may ask for
354
+ one-time Keychain approval. `SOOTSIM_NO_OPEN=1` keeps the server headless. The
355
+ Metro wrapper also has two independent non-window opt-ins.
350
356
  `devServer` serves the RNX shell from the Metro process. `productionBundles`
351
357
  lets explicitly marked production bundle requests use the RNX host
352
358
  implementations of React and React Native while the rest of the app receives
@@ -10,19 +10,6 @@ function serverLabel(server: DiscoveredServer): string {
10
10
  return `${server.projectName?.trim() || server.framework} on :${server.port}`
11
11
  }
12
12
 
13
- async function chooseServer(
14
- discovered: DiscoveredServer[],
15
- ): Promise<DiscoveredServer | null> {
16
- if (discovered.length === 0) return null
17
- const ordered = [...discovered].sort((a, b) => a.port - b.port)
18
- if (ordered.length === 1 || !canPromptForPrivacyChoice()) return ordered[0] ?? null
19
- const selected = await select(
20
- 'which running app should rnx open?',
21
- ordered.map(serverLabel),
22
- )
23
- return ordered[selected] ?? ordered[0] ?? null
24
- }
25
-
26
13
  export async function runWelcome(): Promise<number> {
27
14
  const privacy = readPrivacyPreferences()
28
15
  console.log('\n welcome to rnx')
@@ -31,14 +18,29 @@ export async function runWelcome(): Promise<number> {
31
18
  )
32
19
  console.log(' looking for a running React Native app…')
33
20
 
34
- const selected = await chooseServer(
35
- await scanDevServers({ excludePorts: [DEFAULT_SOOTSIM_BRIDGE_PORT] }),
36
- )
37
- if (!selected) {
21
+ const discovered = await scanDevServers({
22
+ excludePorts: [DEFAULT_SOOTSIM_BRIDGE_PORT],
23
+ })
24
+ const ordered = [...discovered].sort((a, b) => a.port - b.port)
25
+ if (ordered.length === 0) {
38
26
  console.error(' no running React Native development server found.')
39
27
  console.error(' start your app normally, then run `npx rnxsim` again.')
40
28
  return 1
41
29
  }
30
+ if (ordered.length > 1 && !canPromptForPrivacyChoice()) {
31
+ console.error(' multiple React Native development servers found.')
32
+ for (const server of ordered) {
33
+ console.error(` ${serverLabel(server)}: rnx open ${server.port}`)
34
+ }
35
+ console.error(' choose one explicitly; automated runs do not guess.')
36
+ return 1
37
+ }
38
+ const selectedIndex =
39
+ ordered.length === 1
40
+ ? 0
41
+ : await select('which running app should rnx open?', ordered.map(serverLabel))
42
+ const selected = ordered[selectedIndex]
43
+ if (!selected) throw new Error('rnx app selection returned an invalid choice')
42
44
 
43
45
  console.log(` found ${serverLabel(selected)} · opening simulator…`)
44
46
  const bridgePort = await runOpenCommand([selected.bundleUrl])
@@ -101,7 +101,7 @@ export const DECLARED_OUTBOUND_CALLS: Record<string, OutboundCallDeclaration> =
101
101
  category: 'local_development',
102
102
  count: 1,
103
103
  },
104
- "packages/sootsim/scripts/dev-server-scanner.ts :: http.request :: { hostname: 'localhost', port, path, method, timeout, headers }":
104
+ 'packages/sootsim/scripts/dev-server-scanner.ts :: http.request :: { hostname, port, path, method, timeout, headers }':
105
105
  {
106
106
  category: 'local_development',
107
107
  count: 1,
package/dist-cli/bin.js CHANGED
@@ -1,15 +1,15 @@
1
1
  #!/usr/bin/env node
2
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
3
3
  import { createRequire as __sootsimCreateRequire } from 'node:module'
4
4
  var require = __sootsimCreateRequire(import.meta.url)
5
- import{a as g,b as f}from"./chunks/chunk-HXE344V3.js";import{a as m}from"./chunks/chunk-PLUWN2V5.js";import"./chunks/chunk-LAQGSSTT.js";function A(a){let t=a instanceof Error?a.message:String(a);(/^command timed out after \d+s$/.test(t)||t.startsWith("sim disconnected:")||t.startsWith("bridge never reconnected")||t.startsWith("multiple sims are connected:")||t.startsWith("saved sim ")||t.startsWith("no sim connected with id ")||t.startsWith("could not connect to ws://")||t.startsWith("rnx bridge daemon is not running")||t.startsWith("rnx bridge lockfile is fresh")||t.startsWith("rnx bridge exited before becoming ready")||t.startsWith(`${m.commandName} open: requested bridge port`)||t.startsWith("background daemon setup is unavailable")||t.startsWith("rnx bridge did not start within"))&&!process.env.SOOTSIM_VERBOSE&&(process.stderr.write(` ${t}
5
+ import{a as g,b as f}from"./chunks/chunk-ZY44NCRQ.js";import{a as m}from"./chunks/chunk-XGUCAKZM.js";import"./chunks/chunk-DC4MQAR3.js";function A(a){let t=a instanceof Error?a.message:String(a);(/^command timed out after \d+s$/.test(t)||t.startsWith("sim disconnected:")||t.startsWith("bridge never reconnected")||t.startsWith("multiple sims are connected:")||t.startsWith("saved sim ")||t.startsWith("no sim connected with id ")||t.startsWith("could not connect to ws://")||t.startsWith("rnx bridge daemon is not running")||t.startsWith("rnx bridge lockfile is fresh")||t.startsWith("rnx bridge exited before becoming ready")||t.startsWith(`${m.commandName} open: requested bridge port`)||t.startsWith("background daemon setup is unavailable")||t.startsWith("rnx bridge did not start within"))&&!process.env.SOOTSIM_VERBOSE&&(process.stderr.write(` ${t}
6
6
  `),process.exit(1)),a instanceof Error&&a.stack?process.stderr.write(`${a.stack}
7
7
  `):process.stderr.write(`${t}
8
8
  `),process.exit(1)}process.on("unhandledRejection",A);process.on("uncaughtException",A);var k=typeof __SOOTSIM_STANDALONE__<"u"&&__SOOTSIM_STANDALONE__,S=new Set(["desktop"]);function C(a){!k||!S.has(a)||(process.stderr.write(` ${m.commandName} ${a} isn't available in the standalone binary \u2014
9
9
  it needs vite / electron / playwright from a project's node_modules.
10
10
  run the npm package instead:
11
11
  ${m.commandName} ${a}
12
- `),process.exit(1))}var e=f(process.argv);if(!e.command&&e.commandArgs.length>0){let{resolveHiddenRuntimeAlias:a}=await import("./chunks/hidden-runtime-alias-VSJNNSNI.js");e=a(e)}var $=e.command==="cleanup"&&e.commandArgs.length===1&&e.commandArgs[0]==="--automatic-worker";if(!$&&!e.help&&!e.version&&e.command!=="config"&&e.command!=="telemetry"){let{ensurePrivacyChoice:a}=await import("./chunks/privacy-H5KNRNIZ.js");await a({prompt:!0})}if(e.command!=="serve"&&e.command!=="daemon"){let{consumeRuntimeUpgradeNotice:a}=await import("./chunks/home-paths-75HP3HKA.js"),t=a();t&&process.stderr.write(` ${m.name} engine upgraded to v${t.to}`+(t.from?` (from v${t.from})`:"")+` \xB7 what's new: ${m.origin}/changelog
13
- `)}var h=!1;async function v(){if(!h&&(h=!0,!(e.command==="cleanup"||e.command==="serve"||e.command==="agent-wrapper"||e.command==="daemon"&&e.commandArgs[0]==="uninstall")))try{let{isAutomaticSootsimCleanupComplete:a}=await import("./chunks/disk-cleanup-T277L6ZO.js");if(a())return;let{spawn:t}=await import("node:child_process"),i=["cleanup","--automatic-worker"],d=process.argv[1],p=k?t(process.execPath,i,{detached:!0,stdio:["ignore","ignore","inherit"],env:process.env}):d?t(process.execPath,[d,...i],{detached:!0,stdio:["ignore","ignore","inherit"],env:process.env}):t(m.commandName,i,{detached:!0,stdio:["ignore","ignore","inherit"],env:process.env});p.once("error",w=>{process.stderr.write(` ${m.name} automatic cleanup will retry on the next run: ${w.message}
12
+ `),process.exit(1))}var e=f(process.argv);if(!e.command&&e.commandArgs.length>0){let{resolveHiddenRuntimeAlias:a}=await import("./chunks/hidden-runtime-alias-W375XBOM.js");e=a(e)}var $=e.command==="cleanup"&&e.commandArgs.length===1&&e.commandArgs[0]==="--automatic-worker";if(!$&&!e.help&&!e.version&&e.command!=="config"&&e.command!=="telemetry"){let{ensurePrivacyChoice:a}=await import("./chunks/privacy-3BERNBUM.js");await a({prompt:!0})}if(e.command!=="serve"&&e.command!=="daemon"){let{consumeRuntimeUpgradeNotice:a}=await import("./chunks/home-paths-CIGRWLDB.js"),t=a();t&&process.stderr.write(` ${m.name} engine upgraded to v${t.to}`+(t.from?` (from v${t.from})`:"")+` \xB7 what's new: ${m.origin}/changelog
13
+ `)}var h=!1;async function v(){if(!h&&(h=!0,!(e.command==="cleanup"||e.command==="serve"||e.command==="agent-wrapper"||e.command==="daemon"&&e.commandArgs[0]==="uninstall")))try{let{isAutomaticSootsimCleanupComplete:a}=await import("./chunks/disk-cleanup-YAXG52EZ.js");if(a())return;let{spawn:t}=await import("node:child_process"),i=["cleanup","--automatic-worker"],d=process.argv[1],p=k?t(process.execPath,i,{detached:!0,stdio:["ignore","ignore","inherit"],env:process.env}):d?t(process.execPath,[d,...i],{detached:!0,stdio:["ignore","ignore","inherit"],env:process.env}):t(m.commandName,i,{detached:!0,stdio:["ignore","ignore","inherit"],env:process.env});p.once("error",w=>{process.stderr.write(` ${m.name} automatic cleanup will retry on the next run: ${w.message}
14
14
  `)}),p.unref()}catch(a){process.stderr.write(` ${m.name} automatic cleanup will retry on the next run: ${a instanceof Error?a.message:String(a)}
15
- `)}}async function o(a){let{flushCliTelemetry:t}=await import("./chunks/telemetry-JLHFMD7N.js");await t(),await v(),process.exit(a)}if(e.version){let{getCliVersion:a}=await import("./chunks/cli-version-2B4KRNML.js"),{IS_BETA:t,BETA_LABEL:i}=await import("./chunks/beta-EBDIGV3E.js"),d=t?` \xB7 ${i}`:"";console.log(`${m.commandName} v${a()}${d}`);let{readActiveRuntime:p}=await import("./chunks/home-paths-75HP3HKA.js"),w=p();console.log(w?`runtime v${w}`:"runtime not installed"),await o(0)}if(e.help&&!e.command){let{printHelp:a}=await import("./chunks/help-DROVDXJM.js");a(),await o(0)}var n=e.globalFlags.port,c=e.verbose,u=e.globalFlags.device,l=e.globalFlags.theme,y=e.globalFlags.driver,x=e.globalFlags.headless===!0,b=e.globalFlags.sim??e.globalFlags.session??e.globalFlags.tab,r=b?["--sim",b,...e.commandArgs]:e.commandArgs;if(u||l){let{settingsStore:a}=await import("./chunks/store-BYTCKNIC.js"),t={};u&&(t.deviceModel=u),l&&(t.colorScheme=l),a.apply(t)}if(!e.command&&e.commandArgs.length===0){let{runWelcome:a}=await import("./chunks/welcome-6RS7PEJW.js");await o(await a())}var s=e.command??"";if(!s){if(e.commandArgs.length>0){let t=e.commandArgs.find(i=>!i.startsWith("-"))??e.commandArgs[0];console.error(` unknown command: ${t}`),console.error(` run \`${m.commandName} --help\` to see the full surface.`),await o(1)}let{printHelp:a}=await import("./chunks/help-DROVDXJM.js");a(),await o(0)}if(e.help||e.commandArgs.includes("--help")||e.commandArgs.includes("-h")){if(s==="skill"){let{runSkill:i}=await import("./chunks/skills-A7YC6RL5.js");await i(e.commandArgs),await o(0)}if(s==="state"){let{runState:i}=await import("./chunks/state-IJI5YROJ.js");await o(await i(r,{port:n}))}if(s==="reset"){let{runReset:i}=await import("./chunks/reset-5LZN5P5B.js");await o(await i(r,{port:n}))}let a=s==="do"||s==="get"||s==="debug"||s==="shell"||s==="perf"||s==="wait",t=e.commandArgs.find(i=>!i.startsWith("-"));if(!(s==="shell"||s==="perf"))if(a&&!t){let{printGroupHelp:i}=await import("./chunks/help-DROVDXJM.js");i(s)&&await o(0)}else{let{printCommandHelp:i}=await import("./chunks/help-DROVDXJM.js");i(a&&t?t:s,{prefer:a&&t?"verb":"command",group:a&&t?s:void 0}),await o(0)}}C(s);if(g.has(s)){let{runInspect:a}=await import("./chunks/inspect-MDA7ESGQ.js");await a([s,...r],{port:n,verbose:c})}else switch(s){case"assert":{let{runAssert:a}=await import("./chunks/assert-CJKIP4LN.js");await a(e.commandArgs);break}case"detox":{let{runDetox:a}=await import("./chunks/detox-ZC7NHLJI.js");await a(e.commandArgs,{port:n,verbose:c});break}case"maestro":{let{runMaestro:a}=await import("./chunks/maestro-LE5LCRBL.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"record":{let{runRecord:a}=await import("./chunks/record-YJF4KXMR.js");await a(r,{port:n,verbose:c});break}case"film":{let{runFilm:a}=await import("./chunks/film-G7ZAPWB7.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"storage":{let{runStorage:a}=await import("./chunks/storage-Z2DBO2PQ.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"state":{let{runState:a}=await import("./chunks/state-IJI5YROJ.js"),t=await a(r,{port:n});await o(t)}case"reset":{let{runReset:a}=await import("./chunks/reset-5LZN5P5B.js"),t=await a(r,{port:n});await o(t)}case"perf":{let{runPerf:a}=await import("./chunks/perf-NXQZISN6.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"screenshot":{let{runScreenshotCommand:a}=await import("./chunks/screenshot-command-VRPJXWFS.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"camera":{let{runCamera:a}=await import("./chunks/camera-5F4KKCQ3.js"),t=await a(r,{port:n});await o(typeof t=="number"?t:0)}case"mode":{let{runMode:a}=await import("./chunks/mode-BWX6MDPJ.js");await a(r,{port:n,verbose:c});break}case"permissions":{let{runPermissions:a}=await import("./chunks/permissions-5PD67RRO.js"),t=await a(r,{port:n,verbose:c});await o(t)}case"debug":{let{runDebug:a}=await import("./chunks/debug-JICITUB6.js");await a(r,{port:n,verbose:c});break}case"timeline":{let{runTimeline:a}=await import("./chunks/timeline-N7V2M6QA.js");await a(r,{port:n,verbose:c});break}case"what-happened":{let{runWhatHappened:a}=await import("./chunks/what-happened-FUEL3BEF.js");await a(r,{port:n,verbose:c});break}case"open":{let{runOpenCommand:a}=await import("./chunks/control-EV2ELU5R.js");await a(r,{port:n});break}case"use":{let{runUseCommand:a}=await import("./chunks/control-EV2ELU5R.js");await a(r,{port:n});break}case"claim":{let{runClaimCommand:a}=await import("./chunks/control-EV2ELU5R.js");await a(r,{port:n});break}case"close":{let{runCloseCommand:a}=await import("./chunks/control-EV2ELU5R.js");await a(r,{port:n});break}case"device":{let{runDeviceCommand:a}=await import("./chunks/device-V57GHRXX.js");await a(r,{port:n});break}case"compat":{let{runCompat:a}=await import("./chunks/compat-7AURLGCS.js");await a(e.commandArgs);break}case"report-issue":{let{runReportIssue:a}=await import("./chunks/report-issue-XOL5FQBG.js"),t=await a(e.commandArgs);await o(t)}case"desktop":{let{runDesktop:a}=await import("./chunks/desktop-4F5HGLLX.js");await a(e.commandArgs,{port:n,device:u});break}case"login":{let{runLogin:a}=await import("./chunks/login-ZSIHGHUK.js");await a(e.commandArgs);break}case"logout":{let{runLogout:a}=await import("./chunks/logout-Q4DXMI2C.js");await a();break}case"auth":{let{runAuth:a}=await import("./chunks/auth-VHHN3TOB.js");await a(e.commandArgs);break}case"setup":{let{runSetup:a}=await import("./chunks/setup-A6BIG3KL.js");await a(e.commandArgs);break}case"serve":{let{runServe:a}=await import("./chunks/serve-WC6RZNJL.js");await a(e.commandArgs,{port:n});break}case"daemon":{let{runDaemon:a}=await import("./chunks/daemon-KKDG5MYR.js");await a(e.commandArgs,{port:n});break}case"runtime":{let{runRuntime:a}=await import("./chunks/runtime-U36VWBH3.js");await a(e.commandArgs);break}case"upgrade":{let{runUpgrade:a}=await import("./chunks/upgrade-P2NH3BOR.js");await a(e.commandArgs);break}case"version":{let{runVersion:a}=await import("./chunks/version-OUHCSCUS.js");await a(e.commandArgs);break}case"agent":{let{runAgentCommand:a}=await import("./chunks/agent-52G55XTO.js"),t=await a(e.commandArgs);await o(t)}case"agent-wrapper":{let{runAgentWrapper:a}=await import("./chunks/agent-wrapper-BOZM43ON.js"),t=await a(e.commandArgs);await o(t)}case"skill":{let{runSkill:a}=await import("./chunks/skills-A7YC6RL5.js");await a(e.commandArgs);break}case"app-fonts":{let{runAppFonts:a}=await import("./chunks/app-fonts-A2L6V5EZ.js");await a(e.commandArgs);break}case"config":{let{runConfig:a}=await import("./chunks/config-TN3Y4J5N.js");await a(e.commandArgs);break}case"cleanup":{let{runCleanup:a}=await import("./chunks/cleanup-MAVZJXVW.js"),t=await a(e.commandArgs);await o(t)}default:console.error(` unknown command: ${s}`),console.error(` run \`${m.commandName} --help\` to see the full surface.`),await o(1)}await v();
15
+ `)}}async function o(a){let{flushCliTelemetry:t}=await import("./chunks/telemetry-O67J22QU.js");await t(),await v(),process.exit(a)}if(e.version){let{getCliVersion:a}=await import("./chunks/cli-version-BEJJXF35.js"),{IS_BETA:t,BETA_LABEL:i}=await import("./chunks/beta-JXYFAOHO.js"),d=t?` \xB7 ${i}`:"";console.log(`${m.commandName} v${a()}${d}`);let{readActiveRuntime:p}=await import("./chunks/home-paths-CIGRWLDB.js"),w=p();console.log(w?`runtime v${w}`:"runtime not installed"),await o(0)}if(e.help&&!e.command){let{printHelp:a}=await import("./chunks/help-22OURA2E.js");a(),await o(0)}var n=e.globalFlags.port,c=e.verbose,u=e.globalFlags.device,l=e.globalFlags.theme,y=e.globalFlags.driver,x=e.globalFlags.headless===!0,b=e.globalFlags.sim??e.globalFlags.session??e.globalFlags.tab,r=b?["--sim",b,...e.commandArgs]:e.commandArgs;if(u||l){let{settingsStore:a}=await import("./chunks/store-L3A4CLND.js"),t={};u&&(t.deviceModel=u),l&&(t.colorScheme=l),a.apply(t)}if(!e.command&&e.commandArgs.length===0){let{runWelcome:a}=await import("./chunks/welcome-DAZPCMES.js");await o(await a())}var s=e.command??"";if(!s){if(e.commandArgs.length>0){let t=e.commandArgs.find(i=>!i.startsWith("-"))??e.commandArgs[0];console.error(` unknown command: ${t}`),console.error(` run \`${m.commandName} --help\` to see the full surface.`),await o(1)}let{printHelp:a}=await import("./chunks/help-22OURA2E.js");a(),await o(0)}if(e.help||e.commandArgs.includes("--help")||e.commandArgs.includes("-h")){if(s==="skill"){let{runSkill:i}=await import("./chunks/skills-CFCZFEME.js");await i(e.commandArgs),await o(0)}if(s==="state"){let{runState:i}=await import("./chunks/state-XWRKK7FW.js");await o(await i(r,{port:n}))}if(s==="reset"){let{runReset:i}=await import("./chunks/reset-A5AA5ML6.js");await o(await i(r,{port:n}))}let a=s==="do"||s==="get"||s==="debug"||s==="shell"||s==="perf"||s==="wait",t=e.commandArgs.find(i=>!i.startsWith("-"));if(!(s==="shell"||s==="perf"))if(a&&!t){let{printGroupHelp:i}=await import("./chunks/help-22OURA2E.js");i(s)&&await o(0)}else{let{printCommandHelp:i}=await import("./chunks/help-22OURA2E.js");i(a&&t?t:s,{prefer:a&&t?"verb":"command",group:a&&t?s:void 0}),await o(0)}}C(s);if(g.has(s)){let{runInspect:a}=await import("./chunks/inspect-36A2IEJL.js");await a([s,...r],{port:n,verbose:c})}else switch(s){case"assert":{let{runAssert:a}=await import("./chunks/assert-J7N6WGMS.js");await a(e.commandArgs);break}case"detox":{let{runDetox:a}=await import("./chunks/detox-KUZ7EYOP.js");await a(e.commandArgs,{port:n,verbose:c});break}case"maestro":{let{runMaestro:a}=await import("./chunks/maestro-YF4M6M6L.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"record":{let{runRecord:a}=await import("./chunks/record-QHQS2524.js");await a(r,{port:n,verbose:c});break}case"film":{let{runFilm:a}=await import("./chunks/film-KTLKRCJR.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"storage":{let{runStorage:a}=await import("./chunks/storage-C5GNK4XB.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"state":{let{runState:a}=await import("./chunks/state-XWRKK7FW.js"),t=await a(r,{port:n});await o(t)}case"reset":{let{runReset:a}=await import("./chunks/reset-A5AA5ML6.js"),t=await a(r,{port:n});await o(t)}case"perf":{let{runPerf:a}=await import("./chunks/perf-WE6QTFJU.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"screenshot":{let{runScreenshotCommand:a}=await import("./chunks/screenshot-command-WW33MAB3.js"),t=await a(r,{port:n,verbose:c});await o(typeof t=="number"?t:0)}case"camera":{let{runCamera:a}=await import("./chunks/camera-WIVF3UQ3.js"),t=await a(r,{port:n});await o(typeof t=="number"?t:0)}case"mode":{let{runMode:a}=await import("./chunks/mode-6BJ523BY.js");await a(r,{port:n,verbose:c});break}case"permissions":{let{runPermissions:a}=await import("./chunks/permissions-OZZZZFPB.js"),t=await a(r,{port:n,verbose:c});await o(t)}case"debug":{let{runDebug:a}=await import("./chunks/debug-6AQQXXE3.js");await a(r,{port:n,verbose:c});break}case"timeline":{let{runTimeline:a}=await import("./chunks/timeline-7RA7ZILQ.js");await a(r,{port:n,verbose:c});break}case"what-happened":{let{runWhatHappened:a}=await import("./chunks/what-happened-VUNKID5W.js");await a(r,{port:n,verbose:c});break}case"open":{let{runOpenCommand:a}=await import("./chunks/control-7IYIDOOI.js");await a(r,{port:n});break}case"use":{let{runUseCommand:a}=await import("./chunks/control-7IYIDOOI.js");await a(r,{port:n});break}case"claim":{let{runClaimCommand:a}=await import("./chunks/control-7IYIDOOI.js");await a(r,{port:n});break}case"close":{let{runCloseCommand:a}=await import("./chunks/control-7IYIDOOI.js");await a(r,{port:n});break}case"device":{let{runDeviceCommand:a}=await import("./chunks/device-O6WI4PQT.js");await a(r,{port:n});break}case"compat":{let{runCompat:a}=await import("./chunks/compat-5PFPTBBK.js");await a(e.commandArgs);break}case"report-issue":{let{runReportIssue:a}=await import("./chunks/report-issue-SEMVVJUH.js"),t=await a(e.commandArgs);await o(t)}case"desktop":{let{runDesktop:a}=await import("./chunks/desktop-HJE5B4XO.js");await a(e.commandArgs,{port:n,device:u});break}case"login":{let{runLogin:a}=await import("./chunks/login-AJWLXLPQ.js");await a(e.commandArgs);break}case"logout":{let{runLogout:a}=await import("./chunks/logout-CEJLZIOI.js");await a();break}case"auth":{let{runAuth:a}=await import("./chunks/auth-YGX3WVEL.js");await a(e.commandArgs);break}case"setup":{let{runSetup:a}=await import("./chunks/setup-NGZWS373.js");await a(e.commandArgs);break}case"serve":{let{runServe:a}=await import("./chunks/serve-FEBNDKUD.js");await a(e.commandArgs,{port:n});break}case"daemon":{let{runDaemon:a}=await import("./chunks/daemon-G6VR7LJI.js");await a(e.commandArgs,{port:n});break}case"runtime":{let{runRuntime:a}=await import("./chunks/runtime-R26QWA2M.js");await a(e.commandArgs);break}case"upgrade":{let{runUpgrade:a}=await import("./chunks/upgrade-ZW6IJ5LX.js");await a(e.commandArgs);break}case"version":{let{runVersion:a}=await import("./chunks/version-N3E4OIMM.js");await a(e.commandArgs);break}case"agent":{let{runAgentCommand:a}=await import("./chunks/agent-VVY2A5YV.js"),t=await a(e.commandArgs);await o(t)}case"agent-wrapper":{let{runAgentWrapper:a}=await import("./chunks/agent-wrapper-YBMTZ3KU.js"),t=await a(e.commandArgs);await o(t)}case"skill":{let{runSkill:a}=await import("./chunks/skills-CFCZFEME.js");await a(e.commandArgs);break}case"app-fonts":{let{runAppFonts:a}=await import("./chunks/app-fonts-EF7FM3VP.js");await a(e.commandArgs);break}case"config":{let{runConfig:a}=await import("./chunks/config-CG73FOTM.js");await a(e.commandArgs);break}case"cleanup":{let{runCleanup:a}=await import("./chunks/cleanup-ZIDQQLEN.js"),t=await a(e.commandArgs);await o(t)}default:console.error(` unknown command: ${s}`),console.error(` run \`${m.commandName} --help\` to see the full surface.`),await o(1)}await v();
@@ -1,7 +1,7 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
- import{a as b,b as E,c as A,d as l,e as S,g as x,h as j,j as T,n as I,o as k,p as D,q as g,r as O,s as C}from"./chunk-P2CGGMU2.js";import"./chunk-DGTV3KOW.js";import{c as $}from"./chunk-7YMQRA6L.js";import"./chunk-7UIIAHVU.js";import"./chunk-WU72KL6Z.js";import"./chunk-U5YHXQHH.js";import"./chunk-RB4VFUNM.js";import"./chunk-KA4PJNTE.js";import"./chunk-KZFJNDH3.js";import"./chunk-VLBN3KRC.js";import{j as y}from"./chunk-LRM2XCEQ.js";import"./chunk-T7SBFG5I.js";import"./chunk-PLUWN2V5.js";import"./chunk-XXZLK4BY.js";import"./chunk-LAQGSSTT.js";import w from"node:fs";import d from"node:path";import{spawn as _}from"node:child_process";import F from"node:net";import{WebSocket as R}from"ws";var c=class extends Error{code;constructor(e,t){super(e),this.name="AgentDaemonError",this.code=t}},f=class{ws;port;commandTimeoutMs;ready;closed=!1;nextId=1;pending=new Map;eventListeners=new Set;statusListeners=new Set;disconnectListeners=new Set;constructor(e={}){this.port=e.port??7668,this.commandTimeoutMs=e.commandTimeoutMs??15e3,this.ws=new R(`ws://localhost:${this.port}`),this.ready=new Promise((t,r)=>{let s=()=>{this.ws.off("error",o),t()},o=i=>{this.ws.off("open",s),r(new c(`could not connect to rnx daemon on port ${this.port}: ${i.message}`,"NO_DAEMON"))};this.ws.once("open",s),this.ws.once("error",o)}),this.ws.on("message",t=>this.handleMessage(t)),this.ws.on("close",()=>this.handleClose()),this.ws.on("error",()=>{})}async waitReady(){return this.ready}async listProjects(){return this.send("agent:list-projects")}async upsertProject(e){return this.send("agent:upsert-project",{input:e})}async deleteProject(e){return this.send("agent:delete-project",{projectId:e})}async autoAttachForUrl(e){return this.send("agent:auto-attach-for-url",{input:e})}async listSessions(e){return this.send("agent:list-sessions",{projectId:e})}async startSession(e){return this.send("agent:start-session",{input:e})}async sendPrompt(e,t){return this.send("agent:send-prompt",{sessionId:e,prompt:t})}async sendClaimedPrompt(e,t){return this.send("agent:send-claimed-prompt",{simId:e,prompt:t})}async endSession(e){return this.send("agent:end-session",{sessionId:e})}async getTranscript(e){return this.send("agent:get-transcript",{sessionId:e})}async getPaths(){return this.send("agent:get-paths")}async subscribeEvents(e){return this.send("agent:subscribe-events",{sessionId:e})}async unsubscribeEvents(e){return this.send("agent:unsubscribe-events",{sessionId:e})}onAgentEvent(e){return this.eventListeners.add(e),()=>this.eventListeners.delete(e)}onSessionStatusChange(e){return this.statusListeners.add(e),()=>this.statusListeners.delete(e)}onDisconnect(e){return this.disconnectListeners.add(e),()=>this.disconnectListeners.delete(e)}close(){if(!this.closed){this.closed=!0;try{this.ws.close()}catch{}}}async send(e,t={}){if(await this.ready,this.closed||this.ws.readyState!==R.OPEN)throw new c("daemon connection is closed","NO_DAEMON");let r=this.nextId++;return new Promise((s,o)=>{let i=setTimeout(()=>{this.pending.delete(r),o(new c(`${e} timed out after ${Math.round(this.commandTimeoutMs/1e3)}s`,"TIMEOUT"))},this.commandTimeoutMs);this.pending.set(r,{resolve:s,reject:o,timer:i});try{this.ws.send(JSON.stringify({id:r,type:e,...t}))}catch(a){clearTimeout(i),this.pending.delete(r),o(a instanceof Error?a:new Error(String(a)))}})}handleMessage(e){let t;try{t=JSON.parse(String(e))}catch{return}if(!t||typeof t!="object")return;if(t.type==="agent:event"){for(let s of this.eventListeners)try{s({sessionId:t.sessionId,event:t.event})}catch{}return}if(t.type==="agent:session-status"){for(let s of this.statusListeners)try{s(t.session)}catch{}return}if(typeof t.id!="number")return;let r=this.pending.get(t.id);r&&(this.pending.delete(t.id),clearTimeout(r.timer),t.error?r.reject(new c(t.error,t.code)):r.resolve(t.result))}handleClose(){if(!this.closed){this.closed=!0;for(let[,e]of this.pending)clearTimeout(e.timer),e.reject(new c("daemon disconnected","DISCONNECT"));this.pending.clear();for(let e of this.disconnectListeners)try{e()}catch{}}}};function M(n=7668,e=400){return new Promise(t=>{let r=new F.Socket,s=!1,o=i=>{s||(s=!0,r.destroy(),t(i))};r.setTimeout(e),r.once("connect",()=>o(!0)),r.once("timeout",()=>o(!1)),r.once("error",()=>o(!1)),r.connect(n,"127.0.0.1")})}async function B(n={}){let e=n.port??7668;if(await M(e))return{alreadyRunning:!0};if(y())throw new c(`no rnx bridge on port ${e}. run \`rnx setup\` to install the background daemon, or \`rnx serve\` in another shell.`,"DEV_HOST_REFUSED");let{cmd:t,prefixArgs:r}=C(),s=[...r,"serve","--quiet"];e!==7668&&s.push("--port",String(e));let o=_(t,s,{detached:!0,stdio:"ignore",env:process.env,cwd:process.cwd()});o.unref();let i=Date.now()+(n.startupTimeoutMs??5e3);for(;Date.now()<i;){if(await M(e))return{alreadyRunning:!1,pid:o.pid};await new Promise(a=>setTimeout(a,100))}throw new c(`spawned rnx daemon on port ${e} but it did not come up in time. run \`rnx serve\` manually to diagnose.`,"SPAWN_TIMEOUT")}async function h(n={}){await B({port:n.port,startupTimeoutMs:n.startupTimeoutMs});let e=new f(n);try{await e.waitReady()}catch(t){throw e.close(),t}return e}async function ge(n){let[e,...t]=n;try{switch(e){case void 0:case"--help":case"-h":case"help":return L(),0;case"attach":return await W(t);case"projects":return await J();case"project":return await V(t);case"sessions":return await H(t);case"start":return await G(t);case"prompt":return await q(t);case"watch":return await K(t);case"transcript":return await z(t);case"end":return await Q(t);case"paths":return await Y();default:return process.stderr.write(`unknown agent subcommand: ${e}
4
+ import{a as b,b as E,c as A,d as l,e as S,g as x,h as j,j as T,n as I,o as k,p as D,q as g,r as O,s as C}from"./chunk-W4MASUQ7.js";import"./chunk-Z6K6TD7X.js";import{c as $}from"./chunk-7D56NCJ3.js";import"./chunk-EIIZZ2XK.js";import"./chunk-WIYBEKBM.js";import"./chunk-NJ2JVAGV.js";import"./chunk-BAXXUHKV.js";import"./chunk-DTNRKFSE.js";import"./chunk-24Q4J4U6.js";import"./chunk-VENH5KLL.js";import{j as y}from"./chunk-WNZOJDBL.js";import"./chunk-IQWQ6KI7.js";import"./chunk-XGUCAKZM.js";import"./chunk-HY7XOD5E.js";import"./chunk-DC4MQAR3.js";import w from"node:fs";import d from"node:path";import{spawn as _}from"node:child_process";import F from"node:net";import{WebSocket as R}from"ws";var c=class extends Error{code;constructor(e,t){super(e),this.name="AgentDaemonError",this.code=t}},f=class{ws;port;commandTimeoutMs;ready;closed=!1;nextId=1;pending=new Map;eventListeners=new Set;statusListeners=new Set;disconnectListeners=new Set;constructor(e={}){this.port=e.port??7668,this.commandTimeoutMs=e.commandTimeoutMs??15e3,this.ws=new R(`ws://localhost:${this.port}`),this.ready=new Promise((t,r)=>{let s=()=>{this.ws.off("error",o),t()},o=i=>{this.ws.off("open",s),r(new c(`could not connect to rnx daemon on port ${this.port}: ${i.message}`,"NO_DAEMON"))};this.ws.once("open",s),this.ws.once("error",o)}),this.ws.on("message",t=>this.handleMessage(t)),this.ws.on("close",()=>this.handleClose()),this.ws.on("error",()=>{})}async waitReady(){return this.ready}async listProjects(){return this.send("agent:list-projects")}async upsertProject(e){return this.send("agent:upsert-project",{input:e})}async deleteProject(e){return this.send("agent:delete-project",{projectId:e})}async autoAttachForUrl(e){return this.send("agent:auto-attach-for-url",{input:e})}async listSessions(e){return this.send("agent:list-sessions",{projectId:e})}async startSession(e){return this.send("agent:start-session",{input:e})}async sendPrompt(e,t){return this.send("agent:send-prompt",{sessionId:e,prompt:t})}async sendClaimedPrompt(e,t){return this.send("agent:send-claimed-prompt",{simId:e,prompt:t})}async endSession(e){return this.send("agent:end-session",{sessionId:e})}async getTranscript(e){return this.send("agent:get-transcript",{sessionId:e})}async getPaths(){return this.send("agent:get-paths")}async subscribeEvents(e){return this.send("agent:subscribe-events",{sessionId:e})}async unsubscribeEvents(e){return this.send("agent:unsubscribe-events",{sessionId:e})}onAgentEvent(e){return this.eventListeners.add(e),()=>this.eventListeners.delete(e)}onSessionStatusChange(e){return this.statusListeners.add(e),()=>this.statusListeners.delete(e)}onDisconnect(e){return this.disconnectListeners.add(e),()=>this.disconnectListeners.delete(e)}close(){if(!this.closed){this.closed=!0;try{this.ws.close()}catch{}}}async send(e,t={}){if(await this.ready,this.closed||this.ws.readyState!==R.OPEN)throw new c("daemon connection is closed","NO_DAEMON");let r=this.nextId++;return new Promise((s,o)=>{let i=setTimeout(()=>{this.pending.delete(r),o(new c(`${e} timed out after ${Math.round(this.commandTimeoutMs/1e3)}s`,"TIMEOUT"))},this.commandTimeoutMs);this.pending.set(r,{resolve:s,reject:o,timer:i});try{this.ws.send(JSON.stringify({id:r,type:e,...t}))}catch(a){clearTimeout(i),this.pending.delete(r),o(a instanceof Error?a:new Error(String(a)))}})}handleMessage(e){let t;try{t=JSON.parse(String(e))}catch{return}if(!t||typeof t!="object")return;if(t.type==="agent:event"){for(let s of this.eventListeners)try{s({sessionId:t.sessionId,event:t.event})}catch{}return}if(t.type==="agent:session-status"){for(let s of this.statusListeners)try{s(t.session)}catch{}return}if(typeof t.id!="number")return;let r=this.pending.get(t.id);r&&(this.pending.delete(t.id),clearTimeout(r.timer),t.error?r.reject(new c(t.error,t.code)):r.resolve(t.result))}handleClose(){if(!this.closed){this.closed=!0;for(let[,e]of this.pending)clearTimeout(e.timer),e.reject(new c("daemon disconnected","DISCONNECT"));this.pending.clear();for(let e of this.disconnectListeners)try{e()}catch{}}}};function M(n=7668,e=400){return new Promise(t=>{let r=new F.Socket,s=!1,o=i=>{s||(s=!0,r.destroy(),t(i))};r.setTimeout(e),r.once("connect",()=>o(!0)),r.once("timeout",()=>o(!1)),r.once("error",()=>o(!1)),r.connect(n,"127.0.0.1")})}async function B(n={}){let e=n.port??7668;if(await M(e))return{alreadyRunning:!0};if(y())throw new c(`no rnx bridge on port ${e}. run \`rnx setup\` to install the background daemon, or \`rnx serve\` in another shell.`,"DEV_HOST_REFUSED");let{cmd:t,prefixArgs:r}=C(),s=[...r,"serve","--quiet"];e!==7668&&s.push("--port",String(e));let o=_(t,s,{detached:!0,stdio:"ignore",env:process.env,cwd:process.cwd()});o.unref();let i=Date.now()+(n.startupTimeoutMs??5e3);for(;Date.now()<i;){if(await M(e))return{alreadyRunning:!1,pid:o.pid};await new Promise(a=>setTimeout(a,100))}throw new c(`spawned rnx daemon on port ${e} but it did not come up in time. run \`rnx serve\` manually to diagnose.`,"SPAWN_TIMEOUT")}async function h(n={}){await B({port:n.port,startupTimeoutMs:n.startupTimeoutMs});let e=new f(n);try{await e.waitReady()}catch(t){throw e.close(),t}return e}async function ge(n){let[e,...t]=n;try{switch(e){case void 0:case"--help":case"-h":case"help":return L(),0;case"attach":return await W(t);case"projects":return await J();case"project":return await V(t);case"sessions":return await H(t);case"start":return await G(t);case"prompt":return await q(t);case"watch":return await K(t);case"transcript":return await z(t);case"end":return await Q(t);case"paths":return await Y();default:return process.stderr.write(`unknown agent subcommand: ${e}
5
5
  `),L(),2}}catch(r){if(r instanceof c)return process.stderr.write(`${r.message}
6
6
  `),1;throw r}}async function v(n){let e=await h({clientLabel:"sootsim-agent-cli"});try{return await n(e)}finally{e.close()}}function L(){$("agent")}function P(n,e){let t={},r=[];for(let s=0;s<n.length;s++){let o=n[s],i=e[o];i==="value"?(t[o]=n[s+1]??"",s++):i==="bool"?t[o]=!0:r.push(o)}return{flags:t,positional:r}}function U(n,e="codex"){return n==="codex"||n==="claude"?n:e}async function W(n){let{flags:e,positional:t}=P(n,{"--name":"value","--provider":"value"}),r=t[0];if(!r)return process.stderr.write(`usage: rnx agent attach <dir> [--name X] [--provider codex|claude]
7
7
  `),2;let s=d.resolve(r);if(!w.existsSync(s))return process.stderr.write(`directory does not exist: ${s}
@@ -1,7 +1,7 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
- import{b as M}from"./chunk-DGTV3KOW.js";import"./chunk-LAQGSSTT.js";import{execFile as G,spawn as q}from"node:child_process";import{randomUUID as X}from"node:crypto";import{constants as R,createReadStream as Y,createWriteStream as j,existsSync as C,openSync as J}from"node:fs";import V from"node:fs/promises";import z from"node:path";import K from"node:readline";import{promisify as Q}from"node:util";import{spawn as H}from"node:child_process";import L from"node:readline";var b=class extends Error{code;data;constructor(t,r,m){super(t),this.name="CodexRpcError",this.code=r,this.data=m}};function W(d){let t=H(d.bin,["app-server"],{cwd:d.cwd,env:{...process.env,...d.env},stdio:["pipe","pipe","pipe"]}),r=new Map,m=new Map,u=1,f=!1,a=new Promise(s=>{t.on("exit",(o,e)=>{f=!0;let p=new Error(`codex app-server exited (code=${o}, signal=${e??""})`);for(let{reject:y}of r.values())y(p);r.clear(),s({code:o,signal:e})})});L.createInterface({input:t.stdout,crlfDelay:1/0}).on("line",s=>{let o=s.trim();if(!o)return;let e;try{e=JSON.parse(o)}catch{return}if(e.id!=null&&(e.result!==void 0||e.error!==void 0)){let p=typeof e.id=="string"?Number(e.id):e.id,y=p!=null?r.get(p):void 0;if(!y)return;r.delete(p),e.error?y.reject(new b(e.error.message,e.error.code,e.error.data)):y.resolve(e.result);return}if(e.method){let p=m.get(e.method);if(!p)return;for(let y of p)try{y(e.params)}catch(l){console.error(`[codex-client] handler for "${e.method}" threw:`,l instanceof Error?l.stack??l.message:l)}}}),t.stderr.setEncoding("utf8"),t.stderr.on("data",s=>{let o=m.get("__stderr__");if(o)for(let e of o)try{e({text:s})}catch{}});function n(s){if(!f)try{t.stdin.write(JSON.stringify(s)+`
4
+ import{b as M}from"./chunk-Z6K6TD7X.js";import"./chunk-DC4MQAR3.js";import{execFile as G,spawn as q}from"node:child_process";import{randomUUID as X}from"node:crypto";import{constants as R,createReadStream as Y,createWriteStream as j,existsSync as C,openSync as J}from"node:fs";import V from"node:fs/promises";import z from"node:path";import K from"node:readline";import{promisify as Q}from"node:util";import{spawn as H}from"node:child_process";import L from"node:readline";var b=class extends Error{code;data;constructor(t,r,m){super(t),this.name="CodexRpcError",this.code=r,this.data=m}};function W(d){let t=H(d.bin,["app-server"],{cwd:d.cwd,env:{...process.env,...d.env},stdio:["pipe","pipe","pipe"]}),r=new Map,m=new Map,u=1,f=!1,a=new Promise(s=>{t.on("exit",(o,e)=>{f=!0;let p=new Error(`codex app-server exited (code=${o}, signal=${e??""})`);for(let{reject:y}of r.values())y(p);r.clear(),s({code:o,signal:e})})});L.createInterface({input:t.stdout,crlfDelay:1/0}).on("line",s=>{let o=s.trim();if(!o)return;let e;try{e=JSON.parse(o)}catch{return}if(e.id!=null&&(e.result!==void 0||e.error!==void 0)){let p=typeof e.id=="string"?Number(e.id):e.id,y=p!=null?r.get(p):void 0;if(!y)return;r.delete(p),e.error?y.reject(new b(e.error.message,e.error.code,e.error.data)):y.resolve(e.result);return}if(e.method){let p=m.get(e.method);if(!p)return;for(let y of p)try{y(e.params)}catch(l){console.error(`[codex-client] handler for "${e.method}" threw:`,l instanceof Error?l.stack??l.message:l)}}}),t.stderr.setEncoding("utf8"),t.stderr.on("data",s=>{let o=m.get("__stderr__");if(o)for(let e of o)try{e({text:s})}catch{}});function n(s){if(!f)try{t.stdin.write(JSON.stringify(s)+`
5
5
  `)}catch{}}return{exited:a,on(s,o){let e=m.get(s);return e||(e=new Set,m.set(s,e)),e.add(o),()=>{e?.delete(o)}},request(s,o){if(f)return Promise.reject(new Error(`codex app-server closed; cannot call ${s}`));let e=u++;return new Promise((p,y)=>{r.set(e,{resolve:l=>p(l),reject:y,method:s}),n({jsonrpc:"2.0",id:e,method:s,params:o})})},notify(s,o){n({jsonrpc:"2.0",method:s,params:o})},async shutdown(s=1500){if(f)return;try{t.stdin.end()}catch{}let o=setTimeout(()=>{if(!f)try{t.kill("SIGTERM")}catch{}},s);try{await a}finally{clearTimeout(o)}},kill(s="SIGTERM"){if(!f)try{t.kill(s)}catch{}}}}var O="never",F="danger-full-access",Z={type:"dangerFullAccess"},D="fast",ee="medium",te=Q(G);async function ne(d,t){let r=t||d;if(r.includes("/")||r.includes("\\"))return C(r)?{ok:!0,path:r}:{ok:!1,message:`agent binary not found at path: ${r}`};try{let{stdout:m}=await te("which",[r],{timeout:1500}),u=m.trim();return u?{ok:!0,path:u}:{ok:!1,message:`${r} not found on PATH`}}catch{return{ok:!1,message:`${r} not found on PATH. install the ${d} CLI and retry, or pass --${d}-bin /path/to/${d} to agent start.`}}}function re(d){let t={"--session-id":"sessionId","--project-id":"projectId","--provider":"provider","--cwd":"cwd","--prompt-in":"promptIn","--events-out":"eventsOut","--transcript":"transcript","--codex-bin":"codexBin","--claude-bin":"claudeBin","--claude-session-uuid":"claudeSessionUuid"},r={};for(let m=0;m<d.length;m++){let u=d[m];if(u==="--fresh-thread"){r.freshThread=!0;continue}let f=t[u];f&&(r[f]=d[m+1],m++)}return r}async function Ie(d){let t=re(d);if(!t.sessionId||!t.projectId||!t.provider||!t.cwd||!t.promptIn||!t.eventsOut)return process.stderr.write(`usage: rnx agent-wrapper --session-id <id> --project-id <id>
6
6
  --provider codex|claude --cwd <path>
7
7
  --prompt-in <fifo> --events-out <fifo>
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
- import{m as p}from"./chunk-TOF5TA5X.js";import"./chunk-R7ZNRGQN.js";import"./chunk-E2RGSCHT.js";import"./chunk-LAQGSSTT.js";import{existsSync as h,mkdirSync as d,readFileSync as y,writeFileSync as g}from"node:fs";import{join as m}from"node:path";import{gzipSync as w}from"node:zlib";function f(t,e){let o=t.indexOf(`--${e}`);if(o!==-1&&o+1<t.length)return t[o+1];let r=t.find(i=>i.startsWith(`--${e}=`));return r?r.slice(e.length+3):void 0}async function x(t){let e=f(t,"wire")||"",o=f(t,"out-dir"),r=f(t,"manifest");if((!o||!r)&&(console.error(" usage: rnx app-fonts stage --wire <wire> --out-dir <dir> --manifest <path>"),process.exit(1)),!e.trim()){console.log("no app fonts declared \u2014 nothing to stage");return}d(o,{recursive:!0});let i=await p(e,{onStaged:({url:n,byteLength:s})=>console.log(` staged app font: ${n} (${(s/1024).toFixed(1)} KiB)`),onError:(n,s)=>console.error(` warning: failed to fetch app font ${n}: ${s instanceof Error?s.message:s}`)}),a=[];for(let n of i){let s=w(n.bytes);g(m(o,n.urlhash),s),a.push({url:n.url,urlhash:n.urlhash,contentType:n.contentType,encoding:"gzip",sizeBytes:s.length,rawBytes:n.bytes.byteLength})}let c=[];if(h(r))try{let n=JSON.parse(y(r,"utf8"));Array.isArray(n)&&(c=n)}catch{}let u=new Set(c.map(n=>n.urlhash)),l=[...c,...a.filter(n=>!u.has(n.urlhash))];g(r,JSON.stringify(l)),console.log(`staged ${a.length} app font(s); manifest now has ${l.length} file(s)`)}async function E(t){let e=t[0];if(e==="stage"){await x(t.slice(1));return}console.error(` unknown app-fonts subcommand: ${e??"(none)"}`),console.error(" available: stage"),process.exit(1)}export{E as runAppFonts};
4
+ import{o as p}from"./chunk-2E5KDIGN.js";import"./chunk-SYQZTZTR.js";import"./chunk-3SPBSEVL.js";import"./chunk-DC4MQAR3.js";import{existsSync as h,mkdirSync as d,readFileSync as y,writeFileSync as g}from"node:fs";import{join as m}from"node:path";import{gzipSync as w}from"node:zlib";function f(t,e){let o=t.indexOf(`--${e}`);if(o!==-1&&o+1<t.length)return t[o+1];let r=t.find(i=>i.startsWith(`--${e}=`));return r?r.slice(e.length+3):void 0}async function x(t){let e=f(t,"wire")||"",o=f(t,"out-dir"),r=f(t,"manifest");if((!o||!r)&&(console.error(" usage: rnx app-fonts stage --wire <wire> --out-dir <dir> --manifest <path>"),process.exit(1)),!e.trim()){console.log("no app fonts declared \u2014 nothing to stage");return}d(o,{recursive:!0});let i=await p(e,{onStaged:({url:n,byteLength:s})=>console.log(` staged app font: ${n} (${(s/1024).toFixed(1)} KiB)`),onError:(n,s)=>console.error(` warning: failed to fetch app font ${n}: ${s instanceof Error?s.message:s}`)}),a=[];for(let n of i){let s=w(n.bytes);g(m(o,n.urlhash),s),a.push({url:n.url,urlhash:n.urlhash,contentType:n.contentType,encoding:"gzip",sizeBytes:s.length,rawBytes:n.bytes.byteLength})}let c=[];if(h(r))try{let n=JSON.parse(y(r,"utf8"));Array.isArray(n)&&(c=n)}catch{}let u=new Set(c.map(n=>n.urlhash)),l=[...c,...a.filter(n=>!u.has(n.urlhash))];g(r,JSON.stringify(l)),console.log(`staged ${a.length} app font(s); manifest now has ${l.length} file(s)`)}async function E(t){let e=t[0];if(e==="stage"){await x(t.slice(1));return}console.error(` unknown app-fonts subcommand: ${e??"(none)"}`),console.error(" available: stage"),process.exit(1)}export{E as runAppFonts};
@@ -1,7 +1,7 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
- import"./chunk-LAQGSSTT.js";import{spawn as v}from"child_process";var w=new Set(["describe","find","list","network","logs","count","tree","url","a11y","node","layout","keyboard","errors","warnings","requests","animations","animation","state","sample-color"]),S=new Set(["--exists","--empty","--negate","--quiet","--allow-timeout","!"]),q=new Set(["--count","--count-at-least","--count-at-most","--contains","--not-contains","--matches","--not-matches","--equals","--jq","--has-path","--within"]),P=new Set(["--path-equals"]);function j(s){let r=[],u=[],n=0,e=!1,t=!1,i=!1;for(let o=0;o<s.length;o++){let a=s[o];if(a==="--within"){let c=Number(s[o+1]);if(!Number.isFinite(c)||c<0)return{error:`--within requires a non-negative number, got: ${s[o+1]}`};n=c,o++;continue}if(a==="--negate"||a==="!"){e=!0;continue}if(a==="--quiet"){t=!0;continue}if(a==="--allow-timeout"){i=!0;continue}if(S.has(a)){u.push({kind:a,args:[]});continue}if(q.has(a)){let c=s[o+1];if(c==null)return{error:`${a} requires a value`};u.push({kind:a,args:[c]}),o++;continue}if(P.has(a)){let c=s[o+1],f=s[o+2];if(c==null||f==null)return{error:`${a} requires <path> <value>`};u.push({kind:a,args:[c,f]}),o+=2;continue}r.push(a)}return r.length===0?{error:"assert requires a verb (e.g. find, describe, get errors)"}:{verbArgs:r,predicates:u,withinMs:n,negate:e,quiet:t,allowTimeout:i}}function N(s){return s[0]==="get"||s[0]==="debug"?w.has(s[1])?s[1]:null:s[0]==="do"||s[0]==="wait"?null:w.has(s[0])?s[0]:null}async function R(s){let u=[process.argv[1],...s,"--json"];return new Promise(n=>{let e=v(process.execPath,u,{stdio:["ignore","pipe","pipe"],env:process.env}),t="",i="";e.stdout.on("data",o=>t+=o.toString()),e.stderr.on("data",o=>i+=o.toString()),e.on("error",o=>{n({ok:!1,payload:null,reason:`spawn failed: ${o.message}`})}),e.on("close",o=>{if(o!==0){let a=i.trim().split(`
4
+ import"./chunk-DC4MQAR3.js";import{spawn as v}from"child_process";var w=new Set(["describe","find","list","network","logs","count","tree","url","a11y","node","layout","keyboard","errors","warnings","requests","animations","animation","state","sample-color"]),S=new Set(["--exists","--empty","--negate","--quiet","--allow-timeout","!"]),q=new Set(["--count","--count-at-least","--count-at-most","--contains","--not-contains","--matches","--not-matches","--equals","--jq","--has-path","--within"]),P=new Set(["--path-equals"]);function j(s){let r=[],u=[],n=0,e=!1,t=!1,i=!1;for(let o=0;o<s.length;o++){let a=s[o];if(a==="--within"){let c=Number(s[o+1]);if(!Number.isFinite(c)||c<0)return{error:`--within requires a non-negative number, got: ${s[o+1]}`};n=c,o++;continue}if(a==="--negate"||a==="!"){e=!0;continue}if(a==="--quiet"){t=!0;continue}if(a==="--allow-timeout"){i=!0;continue}if(S.has(a)){u.push({kind:a,args:[]});continue}if(q.has(a)){let c=s[o+1];if(c==null)return{error:`${a} requires a value`};u.push({kind:a,args:[c]}),o++;continue}if(P.has(a)){let c=s[o+1],f=s[o+2];if(c==null||f==null)return{error:`${a} requires <path> <value>`};u.push({kind:a,args:[c,f]}),o+=2;continue}r.push(a)}return r.length===0?{error:"assert requires a verb (e.g. find, describe, get errors)"}:{verbArgs:r,predicates:u,withinMs:n,negate:e,quiet:t,allowTimeout:i}}function N(s){return s[0]==="get"||s[0]==="debug"?w.has(s[1])?s[1]:null:s[0]==="do"||s[0]==="wait"?null:w.has(s[0])?s[0]:null}async function R(s){let u=[process.argv[1],...s,"--json"];return new Promise(n=>{let e=v(process.execPath,u,{stdio:["ignore","pipe","pipe"],env:process.env}),t="",i="";e.stdout.on("data",o=>t+=o.toString()),e.stderr.on("data",o=>i+=o.toString()),e.on("error",o=>{n({ok:!1,payload:null,reason:`spawn failed: ${o.message}`})}),e.on("close",o=>{if(o!==0){let a=i.trim().split(`
5
5
  `).slice(-2).join(" | ").slice(0,200);n({ok:!1,payload:null,reason:`verb exited ${o}${a?`: ${a}`:""}`});return}if(!t.trim()){n({ok:!1,payload:null,reason:"verb produced no output"});return}try{let a=JSON.parse(t);n({ok:!0,payload:a})}catch{n({ok:!1,payload:null,reason:`verb output was not valid json: ${t.slice(0,120)}`})}})})}function y(s,r){let u=r.split(".").filter(e=>e.length>0),n=s;for(let e of u){if(n==null)return{found:!1};if(Array.isArray(n)){let t=Number(e);if(!Number.isInteger(t)||t<0||t>=n.length)return{found:!1};n=n[t];continue}if(typeof n=="object"){let t=n;if(!(e in t))return{found:!1};n=t[e];continue}return{found:!1}}return{found:!0,value:n}}function d(s){return Array.isArray(s)?s.length:s&&typeof s=="object"?Object.keys(s).length:null}async function A(s,r){let{kind:u,args:n}=s;switch(u){case"--exists":return r==null?{ok:!1,reason:"payload is null"}:d(r)===0?{ok:!1,reason:"payload is empty"}:{ok:!0,reason:"exists"};case"--empty":{if(r==null)return{ok:!0,reason:"payload is null"};let e=d(r);return e===0?{ok:!0,reason:"payload is empty"}:{ok:!1,reason:`payload has ${e} item(s)`}}case"--count":{let e=Number(n[0]),t=d(r);return t==null?{ok:!1,reason:`payload not countable (${typeof r})`}:{ok:t===e,reason:`count=${t}, want=${e}`}}case"--count-at-least":{let e=Number(n[0]),t=d(r);return t==null?{ok:!1,reason:"payload not countable"}:{ok:t>=e,reason:`count=${t}, want>=${e}`}}case"--count-at-most":{let e=Number(n[0]),t=d(r);return t==null?{ok:!1,reason:"payload not countable"}:{ok:t<=e,reason:`count=${t}, want<=${e}`}}case"--contains":{let e=n[0],t=JSON.stringify(r);return{ok:t.includes(e),reason:t.includes(e)?`contains "${e}"`:`missing "${e}"`}}case"--not-contains":{let e=n[0],t=JSON.stringify(r);return{ok:!t.includes(e),reason:t.includes(e)?`unexpected "${e}"`:`not contains "${e}"`}}case"--matches":{let e=new RegExp(n[0]),t=JSON.stringify(r),i=e.test(t);return{ok:i,reason:i?`matches /${n[0]}/`:`no match for /${n[0]}/`}}case"--not-matches":{let e=new RegExp(n[0]),t=JSON.stringify(r),i=!e.test(t);return{ok:i,reason:i?`not matches /${n[0]}/`:`unexpected /${n[0]}/`}}case"--equals":{let e=n[0],t=typeof r=="string"?r:typeof r=="number"||typeof r=="boolean"?String(r):JSON.stringify(r);return{ok:t===e,reason:`got=${JSON.stringify(t)}, want=${JSON.stringify(e)}`}}case"--has-path":{let e=y(r,n[0]);return{ok:e.found,reason:e.found?`path ${n[0]} present`:`path ${n[0]} missing`}}case"--path-equals":{let[e,t]=n,i=y(r,e);if(!i.found)return{ok:!1,reason:`path ${e} missing`};let o=typeof i.value=="string"||typeof i.value=="number"||typeof i.value=="boolean"?String(i.value):JSON.stringify(i.value);return{ok:o===t,reason:`${e}=${o}, want=${t}`}}case"--jq":{let e=n[0];try{let i=(await O(e,r)).trim();return{ok:i.length>0&&i!=="null"&&i!=="false"&&i!=='""',reason:`jq: ${i.slice(0,120)}`}}catch(t){throw new Error(`jq evaluation failed: ${t.message}`)}}default:return{ok:!1,reason:`unknown predicate ${u}`}}}function O(s,r){return new Promise((u,n)=>{let e=v("jq",[s],{stdio:["pipe","pipe","pipe"]}),t="",i="";e.stdout.on("data",o=>t+=o.toString()),e.stderr.on("data",o=>i+=o.toString()),e.on("error",n),e.on("close",o=>{if(o!==0){n(new Error(i.trim()||`jq exited ${o}`));return}u(t)}),e.stdin.end(JSON.stringify(r))})}async function T(s){(s[0]==="--help"||s[0]==="-h"||s.length===0)&&(J(),process.exit(s.length===0?2:0));let r=j(s);"error"in r&&(process.stderr.write(` assert: ${r.error}
6
6
  `),process.exit(2));let{verbArgs:u,predicates:n,withinMs:e,negate:t,quiet:i,allowTimeout:o}=r;N(u)||(process.stderr.write(` assert: unknown or non-read verb: ${u.join(" ")}
7
7
  supported: ${Array.from(w).sort().join(", ")}
@@ -1,7 +1,7 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
- import{a as r}from"./chunk-7LGINKM6.js";import{d as t}from"./chunk-PLB6UVVX.js";import"./chunk-LRM2XCEQ.js";import"./chunk-LAQGSSTT.js";function i(){console.log(`
4
+ import{a as r}from"./chunk-2UZ6QQ6S.js";import{d as t}from"./chunk-23WNLQUB.js";import"./chunk-WNZOJDBL.js";import"./chunk-DC4MQAR3.js";function i(){console.log(`
5
5
  rnx auth \u2014 inspect CLI auth
6
6
 
7
7
  usage:
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
- import{a,b,c,d}from"./chunk-XXZLK4BY.js";import"./chunk-LAQGSSTT.js";export{d as BETA_ASK_HEADLINE,b as BETA_LABEL,c as BETA_TAGLINE,a as IS_BETA};
4
+ import{a,b,c,d}from"./chunk-HY7XOD5E.js";import"./chunk-DC4MQAR3.js";export{d as BETA_ASK_HEADLINE,b as BETA_LABEL,c as BETA_TAGLINE,a as IS_BETA};
@@ -1,7 +1,7 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
- import{m as O}from"./chunk-ZMTZ5G5H.js";import"./chunk-4BIPA7MD.js";import{q as E,s as F,u as N}from"./chunk-KA4PJNTE.js";import"./chunk-KZFJNDH3.js";import{r as S}from"./chunk-LRM2XCEQ.js";import"./chunk-LAQGSSTT.js";import{createHash as I,randomUUID as q}from"node:crypto";import{createReadStream as D}from"node:fs";import m from"node:fs/promises";import f from"node:path";var T="/__camera-fixtures/",J=new Set([".m4v",".mov",".mp4",".webm"]);function _(){console.log(`
4
+ import{m as O}from"./chunk-7C6XE6AT.js";import"./chunk-O7WPHIYQ.js";import{q as E,s as F,u as N}from"./chunk-DTNRKFSE.js";import"./chunk-24Q4J4U6.js";import{r as S}from"./chunk-WNZOJDBL.js";import"./chunk-DC4MQAR3.js";import{createHash as I,randomUUID as q}from"node:crypto";import{createReadStream as D}from"node:fs";import m from"node:fs/promises";import f from"node:path";var T="/__camera-fixtures/",J=new Set([".m4v",".mov",".mp4",".webm"]);function _(){console.log(`
5
5
  rnx camera \u2014 control the simulator camera source
6
6
 
7
7
  usage:
@@ -1,5 +1,5 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
- import{o as d}from"./chunk-LRM2XCEQ.js";import{chmodSync as S,existsSync as f,mkdirSync as A,readFileSync as k,rmSync as o,writeFileSync as y}from"node:fs";import{dirname as c,join as D,resolve as m}from"node:path";var s=1,p="SOOTSIM_SHARED_AUTH_FILE",u="https://contrast.dev";function w(){let t=process.env[p];return t?.trim()?c(m(t)):d()}function a(){let t=process.env[p];return t?.trim()?m(t):D(w(),"desktop-auth.json")}function g(t){if(!t||typeof t!="object")return null;let e=t;return typeof e.id!="string"||!e.id.trim()?null:{id:e.id.trim(),name:typeof e.name=="string"?e.name:void 0,email:typeof e.email=="string"?e.email:void 0,image:typeof e.image=="string"?e.image:void 0,githubUsername:typeof e.githubUsername=="string"?e.githubUsername:void 0,isAdmin:e.isAdmin===!0,teams:Array.isArray(e.teams)?e.teams.map(r=>{if(!r||typeof r!="object")return null;let n=r;return typeof n.id!="string"||typeof n.name!="string"?null:{id:n.id,name:n.name,role:n.role==="owner"?"owner":"member",githubOrg:typeof n.githubOrg=="string"?n.githubOrg:null}}).filter(r=>!!r):void 0}}function v(t){if(!t||typeof t!="object")return null;let e=t;if(e.version!==s||typeof e.token!="string"||!e.token.trim())return null;let r=typeof e.origin=="string"&&e.origin.trim()?e.origin.trim():u,n=e.source==="cli"||e.source==="electron"||e.source==="browser"||e.source==="unknown"?e.source:"unknown",i=typeof e.updatedAt=="string"&&e.updatedAt?e.updatedAt:new Date().toISOString(),h=typeof e.validatedAt=="string"&&e.validatedAt?e.validatedAt:void 0;return{version:s,token:e.token.trim(),user:g(e.user),origin:r,source:n,updatedAt:i,validatedAt:h}}function b(){let t=a();if(!f(t))return null;try{let e=JSON.parse(k(t,"utf8")),r=v(e);return r||(o(t,{force:!0}),null)}catch{return o(t,{force:!0}),null}}function O(t){let e=a();A(c(e),{recursive:!0});let r={version:s,token:t.token.trim(),user:t.user?g(t.user):null,origin:t.origin?.trim()||u,source:t.source,updatedAt:t.updatedAt||new Date().toISOString(),validatedAt:t.validatedAt};y(e,JSON.stringify(r,null,2)+`
4
+ import{o as d}from"./chunk-WNZOJDBL.js";import{chmodSync as S,existsSync as f,mkdirSync as A,readFileSync as k,rmSync as o,writeFileSync as y}from"node:fs";import{dirname as c,join as D,resolve as m}from"node:path";var s=1,p="SOOTSIM_SHARED_AUTH_FILE",u="https://contrast.dev";function w(){let t=process.env[p];return t?.trim()?c(m(t)):d()}function a(){let t=process.env[p];return t?.trim()?m(t):D(w(),"desktop-auth.json")}function g(t){if(!t||typeof t!="object")return null;let e=t;return typeof e.id!="string"||!e.id.trim()?null:{id:e.id.trim(),name:typeof e.name=="string"?e.name:void 0,email:typeof e.email=="string"?e.email:void 0,image:typeof e.image=="string"?e.image:void 0,githubUsername:typeof e.githubUsername=="string"?e.githubUsername:void 0,isAdmin:e.isAdmin===!0,teams:Array.isArray(e.teams)?e.teams.map(r=>{if(!r||typeof r!="object")return null;let n=r;return typeof n.id!="string"||typeof n.name!="string"?null:{id:n.id,name:n.name,role:n.role==="owner"?"owner":"member",githubOrg:typeof n.githubOrg=="string"?n.githubOrg:null}}).filter(r=>!!r):void 0}}function v(t){if(!t||typeof t!="object")return null;let e=t;if(e.version!==s||typeof e.token!="string"||!e.token.trim())return null;let r=typeof e.origin=="string"&&e.origin.trim()?e.origin.trim():u,n=e.source==="cli"||e.source==="electron"||e.source==="browser"||e.source==="unknown"?e.source:"unknown",i=typeof e.updatedAt=="string"&&e.updatedAt?e.updatedAt:new Date().toISOString(),h=typeof e.validatedAt=="string"&&e.validatedAt?e.validatedAt:void 0;return{version:s,token:e.token.trim(),user:g(e.user),origin:r,source:n,updatedAt:i,validatedAt:h}}function b(){let t=a();if(!f(t))return null;try{let e=JSON.parse(k(t,"utf8")),r=v(e);return r||(o(t,{force:!0}),null)}catch{return o(t,{force:!0}),null}}function O(t){let e=a();A(c(e),{recursive:!0});let r={version:s,token:t.token.trim(),user:t.user?g(t.user):null,origin:t.origin?.trim()||u,source:t.source,updatedAt:t.updatedAt||new Date().toISOString(),validatedAt:t.validatedAt};y(e,JSON.stringify(r,null,2)+`
5
5
  `);try{S(e,384)}catch{}return r}function l(){o(a(),{force:!0})}async function E(t){let e=b();if(!e?.token)return null;let r=t||e.origin||u;try{let n=await fetch(`${r.replace(/\/$/,"")}/api/auth/me`,{headers:{authorization:`Bearer ${e.token}`}});if(n.status===401)return l(),null;if(!n.ok)return e;let i=await n.json();return i.user?.id?O({token:e.token,user:i.user,origin:r,source:e.source,validatedAt:new Date().toISOString()}):(l(),null)}catch{return e}}export{b as a,O as b,l as c,E as d};
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.345 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.347 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  import { createRequire as __sootsimCreateRequire } from 'node:module'
3
3
  var require = __sootsimCreateRequire(import.meta.url)
4
4
  import{execFileSync as P}from"child_process";import{readFileSync as a}from"fs";import{createRequire as d}from"module";var s=null,p=null;function k(r){s||(s=w());try{return s(r)}catch{return null}}function x(r){p||(p=_());try{return p(r)}catch{return null}}function _(){if(process.platform==="linux")return r=>{try{return a(`/proc/${r}/comm`,"utf8").trim()||null}catch{return null}};if(process.platform==="darwin"){let r=B();return r||(t=>b().get(t)?.comm||null)}return()=>null}function w(){let r=Number(process.env.PPID);if(Number.isFinite(r)&&r>1&&r!==process.ppid)return()=>r;if(process.platform==="linux")return C();if(process.platform==="darwin"){let t=h();return t||(n=>{let o=b().get(n)?.ppid;return o!==void 0&&o>0?o:null})}return()=>null}var L=2e3,i={readAt:0,rows:new Map};function b(){let r=Date.now();if(i.readAt&&r-i.readAt<L)return i.rows;let t=new Map;try{let n=P("ps",["-eo","pid=,ppid=,comm="],{encoding:"utf8",timeout:5e3,maxBuffer:8388608,stdio:["ignore","pipe","ignore"]});for(let o of n.split(`