@reason-machines/cli-linux-x64 0.2.407 → 0.2.410
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.
- package/THIRD_PARTY_NOTICES.txt +8 -7
- package/bin/reason +2 -2
- package/bin/runtime/srt/sandbox-runtime.mjs +52 -52
- package/bin/vm-hands/api-cjv8m2zy.js +2 -0
- package/bin/vm-hands/api-credentials-m5akr9fv.js +2 -0
- package/bin/vm-hands/connect-cli-nydbj6ae.js +2 -0
- package/bin/vm-hands/custom-endpoint-device-dkqb4rqy.js +2 -0
- package/bin/vm-hands/desktop-account-5v7x0ajx.js +2 -0
- package/bin/vm-hands/device-workspace-p9q9dckg.js +2 -0
- package/bin/vm-hands/fsevents-ekt70rcc.js +2 -0
- package/bin/vm-hands/hands-worker-source-cgrpm21b.js +2 -0
- package/bin/vm-hands/index-k8kcz8a3.js +12818 -0
- package/bin/vm-hands/install-receipt-7vt2y2vh.js +2 -0
- package/bin/vm-hands/local-automation-y9kx76wa.js +2 -0
- package/bin/vm-hands/local-capabilities-j6h63m79.js +2 -0
- package/bin/vm-hands/local-desktop-users-q886k0mm.js +2 -0
- package/bin/vm-hands/local-display-mac-w85956f1.js +2 -0
- package/bin/vm-hands/local-display-session-ftt74eb3.js +2 -0
- package/bin/vm-hands/local-pty-session-5f50sqq0.js +2 -0
- package/bin/vm-hands/managed-runtime-tjwpypgf.js +2 -0
- package/bin/vm-hands/network-contract-9x9kc5vv.js +2 -0
- package/bin/vm-hands/package-78fkast4.js +2 -0
- package/bin/vm-hands/permissions-byngw8v0.js +2 -0
- package/bin/vm-hands/reason-hands-protocol-2tnghj3b.js +2 -0
- package/bin/vm-hands/serve-service-j5wnq4bg.js +2 -0
- package/bin/vm-hands/status-8tjada6n.js +10 -0
- package/bin/vm-hands/version-5hrs2hvb.js +2 -0
- package/bin/vm-hands/vm-hands-entry-lite-05rrh8yg.js +250 -0
- package/bin/vm-hands/vm-hands-entry-lite-09m2cdkw.js +4 -0
- package/bin/vm-hands/vm-hands-entry-lite-0g9xvgdy.js +2 -0
- package/bin/vm-hands/vm-hands-entry-lite-0xrsph3r.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-10sbjfzx.js +9 -0
- package/bin/vm-hands/vm-hands-entry-lite-1cwqa4jr.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-1rrb66r9.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-1rtkf2xm.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-1sg8sdw5.js +5 -0
- package/bin/vm-hands/vm-hands-entry-lite-22kfyvnk.js +2 -0
- package/bin/vm-hands/vm-hands-entry-lite-46fkv5sp.js +105 -0
- package/bin/vm-hands/vm-hands-entry-lite-66ctbcym.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-6aeea05q.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-70ba2bqj.js +458 -0
- package/bin/vm-hands/{vm-hands-entry-lite-vr4sva78.js → vm-hands-entry-lite-80y72d0e.js} +5 -9
- package/bin/vm-hands/vm-hands-entry-lite-88swf2qr.js +6 -0
- package/bin/vm-hands/vm-hands-entry-lite-89z488gz.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-8ns59paz.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-8t9xssf9.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-907pa7f9.js +65 -0
- package/bin/vm-hands/vm-hands-entry-lite-9ay6f56v.js +3 -0
- package/bin/vm-hands/{vm-hands-entry-lite-jcd21jpm.js → vm-hands-entry-lite-9c95p6n9.js} +54 -54
- package/bin/vm-hands/vm-hands-entry-lite-ab2m9erf.js +2 -0
- package/bin/vm-hands/vm-hands-entry-lite-b885gwfh.js +7 -0
- package/bin/vm-hands/{vm-hands-entry-lite-xqve205b.js → vm-hands-entry-lite-bdhjpv7g.js} +2 -2
- package/bin/vm-hands/vm-hands-entry-lite-bk6akkdt.js +540 -0
- package/bin/vm-hands/vm-hands-entry-lite-ckv17tn8.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-eqgj4acy.js +112 -0
- package/bin/vm-hands/vm-hands-entry-lite-f5e3dbgk.js +4 -0
- package/bin/vm-hands/vm-hands-entry-lite-grm1tqs7.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-gvwdy3rf.js +4 -0
- package/bin/vm-hands/vm-hands-entry-lite-hj8n59y9.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-k278g9kj.js +42 -0
- package/bin/vm-hands/{vm-hands-entry-lite-wer0qzxg.js → vm-hands-entry-lite-m11j0f9q.js} +2 -2
- package/bin/vm-hands/vm-hands-entry-lite-pgb514h0.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-pmcz7j7t.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-q0k6kx6d.js +5 -0
- package/bin/vm-hands/vm-hands-entry-lite-qy9xg6em.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-qysyf65v.js +2 -0
- package/bin/vm-hands/vm-hands-entry-lite-r29k28kb.js +14 -0
- package/bin/vm-hands/{vm-hands-entry-lite-fbpxs065.js → vm-hands-entry-lite-t7an5zg2.js} +2 -2
- package/bin/vm-hands/vm-hands-entry-lite-vrqzr15t.js +3 -0
- package/bin/vm-hands/vm-hands-entry-lite-w59z67hf.js +52 -0
- package/bin/vm-hands/vm-hands-entry-lite-zg36myyf.js +5 -0
- package/bin/vm-hands/vm-hands-entry-lite.js +3 -1
- package/bin/vm-hands/vm-hands-executor-rdmj1wv4.js +11 -0
- package/bin/vm-hands/vm-hands-op-runner-f2bjvb7v.js +2 -0
- package/bin/vm-hands/vm-hands-runtime-aa4p4pqz.js +4 -0
- package/bin/vm-hands/worker-sandbox-smqj3mbe.js +2 -0
- package/package.json +1 -1
- package/bin/vm-hands/api-credentials-4e2gypqj.js +0 -2
- package/bin/vm-hands/api-f48wa4ym.js +0 -2
- package/bin/vm-hands/ask-relay-jatz6zdz.js +0 -8
- package/bin/vm-hands/connect-cli-7jc6q164.js +0 -2
- package/bin/vm-hands/custom-endpoint-device-8h95wy87.js +0 -2
- package/bin/vm-hands/desktop-account-2kkxwv1y.js +0 -2
- package/bin/vm-hands/device-workspace-nzz3kd5t.js +0 -2
- package/bin/vm-hands/hands-worker-source-as5wepvk.js +0 -2
- package/bin/vm-hands/index-2kk983b8.js +0 -12818
- package/bin/vm-hands/install-receipt-e6s355j1.js +0 -2
- package/bin/vm-hands/local-automation-c7sk21zn.js +0 -2
- package/bin/vm-hands/local-capabilities-dgaqqaw9.js +0 -2
- package/bin/vm-hands/local-desktop-users-sevkfkye.js +0 -2
- package/bin/vm-hands/local-display-mac-jzc0g5ge.js +0 -2
- package/bin/vm-hands/local-display-session-gcndscvj.js +0 -2
- package/bin/vm-hands/local-pty-session-fe6jz2zy.js +0 -2
- package/bin/vm-hands/managed-runtime-pveke48y.js +0 -2
- package/bin/vm-hands/network-contract-9smga6kn.js +0 -2
- package/bin/vm-hands/package-qjr5q0bp.js +0 -2
- package/bin/vm-hands/permissions-92a6yh7t.js +0 -2
- package/bin/vm-hands/reason-hands-protocol-5fhd49en.js +0 -2
- package/bin/vm-hands/serve-service-rjbca0dj.js +0 -2
- package/bin/vm-hands/status-1tqes7gw.js +0 -96
- package/bin/vm-hands/version-8qryvrwt.js +0 -2
- package/bin/vm-hands/vm-hands-entry-lite-05qq23fw.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-1sc3wc94.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-2nec0vk1.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-2s9the7x.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-32ch1nr1.js +0 -346
- package/bin/vm-hands/vm-hands-entry-lite-40nkzw38.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-4bgxq9ps.js +0 -9
- package/bin/vm-hands/vm-hands-entry-lite-5rkakg10.js +0 -4
- package/bin/vm-hands/vm-hands-entry-lite-69ray4x8.js +0 -6
- package/bin/vm-hands/vm-hands-entry-lite-6berk108.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-72nn2b4n.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-7k3vp3fe.js +0 -52
- package/bin/vm-hands/vm-hands-entry-lite-8f3px72v.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-8gjrr6hg.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-8tcnbfnm.js +0 -5
- package/bin/vm-hands/vm-hands-entry-lite-9vf97byd.js +0 -4
- package/bin/vm-hands/vm-hands-entry-lite-er3nrbb9.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-f6714myc.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-g5c9ec33.js +0 -5
- package/bin/vm-hands/vm-hands-entry-lite-h0y0xv5f.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-h9t84ekh.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-hd4a0a6f.js +0 -112
- package/bin/vm-hands/vm-hands-entry-lite-hepppjp0.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-hye6r7dy.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-jw5y1aa5.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-ky0w7t09.js +0 -42
- package/bin/vm-hands/vm-hands-entry-lite-mapxp682.js +0 -4
- package/bin/vm-hands/vm-hands-entry-lite-mxdztdmq.js +0 -11
- package/bin/vm-hands/vm-hands-entry-lite-np1fcr2t.js +0 -5
- package/bin/vm-hands/vm-hands-entry-lite-nqvb7a2m.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-q4tcfj61.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-q590arx5.js +0 -251
- package/bin/vm-hands/vm-hands-entry-lite-r2xmr627.js +0 -4
- package/bin/vm-hands/vm-hands-entry-lite-r6f6qkw6.js +0 -105
- package/bin/vm-hands/vm-hands-entry-lite-swwb5mp2.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-tkb2b6x8.js +0 -540
- package/bin/vm-hands/vm-hands-entry-lite-va3vbvsk.js +0 -458
- package/bin/vm-hands/vm-hands-entry-lite-vr38bh6k.js +0 -66
- package/bin/vm-hands/vm-hands-entry-lite-wa261sf8.js +0 -3
- package/bin/vm-hands/vm-hands-entry-lite-yg5h9mhm.js +0 -7
- package/bin/vm-hands/vm-hands-entry-lite-yqrmr2c8.js +0 -5
- package/bin/vm-hands/vm-hands-executor-etthkykm.js +0 -11
- package/bin/vm-hands/vm-hands-op-runner-bbp6fzn2.js +0 -2
- package/bin/vm-hands/vm-hands-runtime-2x1ryrxr.js +0 -4
- package/bin/vm-hands/worker-sandbox-p242st5d.js +0 -2
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Ae as s,Be as t,Ce as u,De as v,ie as a,je as b,ke as c,le as d,me as e,ne as f,oe as g,pe as h,qe as i,re as j,se as k,te as l,ue as m,ve as n,we as o,xe as p,ye as q,ze as r}from"./vm-hands-entry-lite-np1fcr2t.js";import"./vm-hands-entry-lite-q4tcfj61.js";import"./vm-hands-entry-lite-fbpxs065.js";import"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{v as runInstallReceiptCli,u as recordInstallationReceipt,o as pathEntryAddedByInstaller,p as parseInstallationReceipt,q as loadInstallationReceipt,l as installerReceiptLauncher,n as installerReasonAlias,i as installerLauncherNames,h as installationReceiptPath,g as installationConfigHome,m as installationAliasMatchesTarget,r as hasInstallationDeviceConsent,s as authorizeInstallationForFutureDevice,t as authorizeDesktopInstallationForFutureDevice,k as INSTALLER_WORKER_EXECUTABLES,j as INSTALLER_WORKER_DIRECTORY,a as INSTALLATION_RECEIPT_SCHEMA_VERSION,b as INSTALLATION_DEVICE_CONSENT_VERSION,f as INSTALLATION_BACKGROUND_MODES,e as FUTURE_DEVICE_CONSENT_SCOPE,c as DESKTOP_ACCOUNT_ACCESS_VERSION,d as DESKTOP_ACCOUNT_ACCESS_SCOPE};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Fd as a,Gd as b,Hd as c,Id as d,Jd as e,Kd as f,Ld as g,Md as h,Nd as i,Od as j,Pd as k,Qd as l}from"./vm-hands-entry-lite-vr4sva78.js";import"./vm-hands-entry-lite-r6f6qkw6.js";import"./vm-hands-entry-lite-np1fcr2t.js";import"./vm-hands-entry-lite-ky0w7t09.js";import"./vm-hands-entry-lite-q590arx5.js";import"./vm-hands-entry-lite-1sc3wc94.js";import"./vm-hands-entry-lite-yqrmr2c8.js";import"./vm-hands-entry-lite-9vf97byd.js";import"./vm-hands-entry-lite-xqve205b.js";import"./vm-hands-entry-lite-mapxp682.js";import"./vm-hands-entry-lite-2nec0vk1.js";import"./vm-hands-entry-lite-q4tcfj61.js";import"./vm-hands-entry-lite-fbpxs065.js";import"./vm-hands-entry-lite-7k3vp3fe.js";import"./vm-hands-entry-lite-8f3px72v.js";import"./vm-hands-entry-lite-4bgxq9ps.js";import"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-f6714myc.js";import"./vm-hands-entry-lite-05qq23fw.js";import"./vm-hands-entry-lite-hd4a0a6f.js";import"./vm-hands-entry-lite-vr38bh6k.js";import"./vm-hands-entry-lite-r2xmr627.js";import"./vm-hands-entry-lite-8gjrr6hg.js";import"./vm-hands-entry-lite-hepppjp0.js";import"./vm-hands-entry-lite-wer0qzxg.js";import"./vm-hands-entry-lite-40nkzw38.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{d as runRelayed,e as runMacComputerUse,l as runLocalAutomation,k as runAutomationCallLocally,b as parseAutomationPayload,g as localUserChromeProfiles,h as localUserChromeInstance,f as localUserChromeHost,j as localBrowserProfile,c as localAutomationAvailable,i as ensureLocalBrowser,a as AUTOMATION_CHUNK_BYTES};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{$a as k,Ta as c,Ua as d,Va as e,Wa as f,Xa as g,Ya as h,Za as i,_a as j,ab as l,bb as m,cb as n,db as o,eb as p,fb as q,gb as r,hb as s,ib as t,jb as u}from"./vm-hands-entry-lite-tkb2b6x8.js";import"./vm-hands-entry-lite-va3vbvsk.js";import"./vm-hands-entry-lite-yg5h9mhm.js";import"./vm-hands-entry-lite-69ray4x8.js";import"./vm-hands-entry-lite-jcd21jpm.js";import"./vm-hands-entry-lite-swwb5mp2.js";import"./vm-hands-entry-lite-5rkakg10.js";import"./vm-hands-entry-lite-nqvb7a2m.js";import"./vm-hands-entry-lite-jw5y1aa5.js";import"./vm-hands-entry-lite-vr4sva78.js";import"./vm-hands-entry-lite-r6f6qkw6.js";import"./vm-hands-entry-lite-np1fcr2t.js";import"./vm-hands-entry-lite-ky0w7t09.js";import"./vm-hands-entry-lite-q590arx5.js";import"./vm-hands-entry-lite-1sc3wc94.js";import"./vm-hands-entry-lite-yqrmr2c8.js";import"./vm-hands-entry-lite-9vf97byd.js";import"./vm-hands-entry-lite-xqve205b.js";import"./vm-hands-entry-lite-mapxp682.js";import"./vm-hands-entry-lite-2nec0vk1.js";import"./vm-hands-entry-lite-q4tcfj61.js";import"./vm-hands-entry-lite-fbpxs065.js";import"./vm-hands-entry-lite-7k3vp3fe.js";import{ej as b}from"./vm-hands-entry-lite-8f3px72v.js";import"./vm-hands-entry-lite-4bgxq9ps.js";import"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-f6714myc.js";import"./vm-hands-entry-lite-05qq23fw.js";import"./vm-hands-entry-lite-hd4a0a6f.js";import"./vm-hands-entry-lite-vr38bh6k.js";import"./vm-hands-entry-lite-r2xmr627.js";import"./vm-hands-entry-lite-8gjrr6hg.js";import"./vm-hands-entry-lite-hepppjp0.js";import"./vm-hands-entry-lite-wer0qzxg.js";import{Rk as a}from"./vm-hands-entry-lite-40nkzw38.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{j as writeOpenFlags,g as spawnCaptured,f as sandboxProfile,e as safeEnvironment,k as runTransferCapability,i as runFileCapability,t as rebindLocalHandsControl,b as isProtectedLocalPath,u as executeLocalOperation,m as enrolledWorkspaceRootFingerprint,q as enrolledRootPaths,p as enrolledHomeContainedRootFingerprints,n as enrolledAccountRootPath,o as enrolledAccountRootFingerprint,s as deliverLocalHandsEnvironment,h as defaultLocalCommandRunner,d as confinedExecutionShell,r as capabilityInventoryForRoots,c as SHORT_REQUEST_CAPABILITIES,a as LocalCapabilityError,l as LOCAL_CAPABILITY_REGISTRY};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Ak as f,Bk as g,vk as a,wk as b,xk as c,yk as d,zk as e}from"./vm-hands-entry-lite-r2xmr627.js";import"./vm-hands-entry-lite-8gjrr6hg.js";import"./vm-hands-entry-lite-hepppjp0.js";import"./vm-hands-entry-lite-wer0qzxg.js";import"./vm-hands-entry-lite-40nkzw38.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{f as trackDesktopRun,c as releaseLocalDesktop,a as noteLocalDesktopUse,g as holdLocalDesktop,b as forgetLocalDesktopUse,e as DESKTOP_WAIT_MS,d as DESKTOP_IDLE_MS};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{nk as a,ok as b,pk as c,qk as d,rk as e,sk as f,tk as g}from"./vm-hands-entry-lite-hd4a0a6f.js";import"./vm-hands-entry-lite-40nkzw38.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{c as requestMacScreenAccess,d as parseMacWindowBounds,a as parseMacScreenStatus,e as openMacWindowBounds,g as openMacInput,b as macScreenStatus,f as MacInputTranslator};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{pg as a,qg as b,rg as c,sg as d,tg as e,ug as f,vg as g,wg as h}from"./vm-hands-entry-lite-q590arx5.js";import"./vm-hands-entry-lite-1sc3wc94.js";import"./vm-hands-entry-lite-yqrmr2c8.js";import"./vm-hands-entry-lite-9vf97byd.js";import"./vm-hands-entry-lite-xqve205b.js";import"./vm-hands-entry-lite-mapxp682.js";import"./vm-hands-entry-lite-2nec0vk1.js";import"./vm-hands-entry-lite-q4tcfj61.js";import"./vm-hands-entry-lite-fbpxs065.js";import"./vm-hands-entry-lite-7k3vp3fe.js";import"./vm-hands-entry-lite-8f3px72v.js";import"./vm-hands-entry-lite-4bgxq9ps.js";import"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-f6714myc.js";import"./vm-hands-entry-lite-05qq23fw.js";import"./vm-hands-entry-lite-hd4a0a6f.js";import"./vm-hands-entry-lite-vr38bh6k.js";import"./vm-hands-entry-lite-r2xmr627.js";import"./vm-hands-entry-lite-8gjrr6hg.js";import"./vm-hands-entry-lite-hepppjp0.js";import"./vm-hands-entry-lite-wer0qzxg.js";import"./vm-hands-entry-lite-40nkzw38.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{h as runLocalDisplayStream,f as privateDirectory,c as parseDisplayStreamPayload,e as localDisplayReady,d as localDisplayAvailable,g as ensureLinuxDesktop,a as LOCAL_DISPLAY_MAX_SESSION_MS,b as LINUX_WORKER_DISPLAY};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Ag as c,Bg as d,Cg as e,Dg as f,Eg as g,Fg as h,Gg as i,Hg as j,yg as a,zg as b}from"./vm-hands-entry-lite-1sc3wc94.js";import"./vm-hands-entry-lite-yqrmr2c8.js";import"./vm-hands-entry-lite-xqve205b.js";import"./vm-hands-entry-lite-mapxp682.js";import"./vm-hands-entry-lite-2nec0vk1.js";import"./vm-hands-entry-lite-q4tcfj61.js";import"./vm-hands-entry-lite-fbpxs065.js";import"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-vr38bh6k.js";import"./vm-hands-entry-lite-hepppjp0.js";import"./vm-hands-entry-lite-40nkzw38.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{j as runLocalPtySession,e as resolvePtyWorkingDirectory,g as ptyRuntimeSupported,d as parsePtyStartPayload,h as defaultSpawnPty,f as defaultLoginShell,i as defaultConnect,a as LOCAL_PTY_MAX_SESSION_MS,c as LOCAL_PTY_MAX_SESSIONS,b as LOCAL_PTY_MAX_BUFFERED_OUTPUT_BYTES};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{$ as D,L as n,M as o,N as p,O as q,P as r,Q as s,R as t,S as u,T as v,U as w,V as x,W as y,X as z,Y as A,Z as B,_ as C,aa as E,ba as F,ca as G,da as H,ea as I,fa as J,ga as K,ha as L,ia as M,ja as N,ka as O,la as P,ma as Q,na as R,oa as S,pa as T,qa as U,ra as V,sa as W,ta as X,ua as Y,va as Z,wa as _}from"./vm-hands-entry-lite-mxdztdmq.js";import"./vm-hands-entry-lite-5rkakg10.js";import"./vm-hands-entry-lite-nqvb7a2m.js";import{gi as a,hi as b,ii as c,ji as d,ki as e,li as f,mi as g,ni as h,pi as i,qi as j,si as k,ti as l,ui as m}from"./vm-hands-entry-lite-2nec0vk1.js";import"./vm-hands-entry-lite-fbpxs065.js";import"./vm-hands-entry-lite-4bgxq9ps.js";import"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-f6714myc.js";import"./vm-hands-entry-lite-05qq23fw.js";import"./vm-hands-entry-lite-8gjrr6hg.js";import"./vm-hands-entry-lite-hepppjp0.js";import"./vm-hands-entry-lite-wer0qzxg.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{G as verifyManagedRuntimeCodeSignatures,m as verifyManagedRuntimeArtifact,J as updateManagedRuntime,l as sha256Hex,S as rollbackManagedRuntime,T as recoverManagedRuntimeActivation,X as recordManagedRuntimeLifecycle,W as readManagedRuntimeLifecycleEvents,j as parseAndVerifyManagedRuntimeManifest,k as parseAndVerifyLegacyManagedRuntimeManifest,B as managedRuntimeVersionPath,E as managedRuntimeTarget,M as managedRuntimePointerVersion,z as managedRuntimePaths,Q as managedRuntimeExecutableVersion,C as managedRuntimeCredentialLibraryPath,h as managedRuntimeCredentialLibraryAssetName,g as managedRuntimeAssetName,A as legacyManagedRuntimePaths,P as isManagedRuntimeVersionExecutable,O as isManagedRuntimeExecutable,L as installManagedRuntimeLauncher,K as installManagedRuntimeArtifact,Z as flushManagedRuntimeLifecycleEvents,H as fetchManagedRuntimeBytes,I as defaultManagedRuntimeHealthCheck,N as currentManagedRuntimeVersion,D as compareManagedRuntimeVersions,i as canonicalJson,_ as bootstrapManagedRuntime,F as assertManagedRuntimeSignatureEvidence,R as activateManagedRuntime,V as acquireManagedRuntimeLock,U as acquireManagedRuntimeDirectoryLock,Y as acknowledgeManagedRuntimeLifecycleEvents,f as ManagedRuntimeError,v as MANAGED_RUNTIME_UPDATE_HEALTH_TIMEOUT_MS,e as MANAGED_RUNTIME_TARGETS,d as MANAGED_RUNTIME_MAX_MANIFEST_BYTES,p as MANAGED_RUNTIME_MAX_LIFECYCLE_EVENTS,q as MANAGED_RUNTIME_MAX_LIFECYCLE_BYTES,c as MANAGED_RUNTIME_MAX_ARTIFACT_BYTES,b as MANAGED_RUNTIME_MANIFEST_VERSION,r as MANAGED_RUNTIME_MANIFEST_URL,o as MANAGED_RUNTIME_LIFECYCLE_VERSION,y as MANAGED_RUNTIME_LIFECYCLE_EVENTS,n as MANAGED_RUNTIME_LAYOUT_VERSION,u as MANAGED_RUNTIME_HEALTH_TIMEOUT_MS,s as MANAGED_RUNTIME_FETCH_TIMEOUT_MS,t as MANAGED_RUNTIME_ARTIFACT_FETCH_TIMEOUT_MS,a as LEGACY_MANAGED_RUNTIME_MANIFEST_VERSION,w as DEVICE_BROKER_SIGNING_IDENTIFIER,x as DEVICE_BROKER_DESIGNATED_REQUIREMENT};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{$e as n,$f as na,Af as O,Bf as P,Cf as Q,Df as R,Ef as S,Ff as T,Gf as U,Hf as V,If as W,Jf as X,Kf as Y,Lf as Z,Mf as _,Nf as $,Oe as a,Of as aa,Pe as b,Pf as ba,Qe as c,Qf as ca,Re as d,Rf as da,Se as e,Sf as ea,Te as f,Tf as fa,Ue as g,Uf as ga,Ve as h,Vf as ha,We as i,Wf as ia,Xe as j,Xf as ja,Ye as k,Yf as ka,Ze as l,Zf as la,_e as m,_f as ma,af as o,ag as oa,bf as p,bg as pa,cf as q,df as r,ef as s,ff as t,gf as u,hf as v,if as w,jf as x,kf as y,lf as z,mf as A,nf as B,of as C,pf as D,qf as E,rf as F,sf as G,tf as H,uf as I,vf as J,wf as K,xf as L,yf as M,zf as N}from"./vm-hands-entry-lite-ky0w7t09.js";import"./vm-hands-entry-lite-vr38bh6k.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{ga as parseLocalRuntimeRootsSyncResponse,ca as parseLocalRuntimeRegistrationResponse,ba as parseLocalRuntimeProofChallenge,ma as parseLocalRuntimeOperationHeartbeatResponse,na as parseLocalRuntimeOperationEventsResponse,oa as parseLocalRuntimeOperationEnvironmentResponse,pa as parseLocalRuntimeOperationCompletionResponse,la as parseLocalRuntimeOperationClaim,ja as parseLocalRuntimeLocalSubscriptionResponse,ka as parseLocalRuntimeLifecycleResponse,ha as parseLocalRuntimeIdentityResponse,ea as parseLocalRuntimeHeartbeatResponse,fa as parseLocalRuntimeFirstHeartbeat,aa as parseLocalRuntimeErrorEnvelope,da as parseLocalRuntimeEnrollmentResponse,ia as parseLocalRuntimeDisconnectResponse,j as localRuntimeSessionRoutable,$ as buildLocalRuntimeDeviceProofBytes,W as WORKER_STARTUP_TIMING_STAGES,R as WORKER_PREVIEW_CARRIED_JOBS,q as VM_HANDS_WORKSPACE_GRANT_CONTROL,p as VM_HANDS_WORKSPACE_DEFERRED_KEY,r as VM_HANDS_UNBIND_UNVERIFIED_EVENT,e as RELAY_HOST_ALIAS_VERSION,d as RELAY_HOST_ALIAS_HEADER,X as LOCAL_RUNTIME_WORKER_STARTUP_MAX_MS,k as LOCAL_RUNTIME_SESSION_VM_HANDS_REGISTER,h as LOCAL_RUNTIME_SESSION_PRE_AUTH_MAX_BYTES,g as LOCAL_RUNTIME_SESSION_PATH,m as LOCAL_RUNTIME_SESSION_CLOSE,l as LOCAL_RUNTIME_SESSION_CLAIM_WAIT_MAX_MS,i as LOCAL_RUNTIME_SESSION_AUTH_DEADLINE_MS,b as LOCAL_RUNTIME_ROUTE_PREFIX,f as LOCAL_RUNTIME_ROUTES,a as LOCAL_RUNTIME_PROTOCOL_VERSION,Y as LOCAL_RUNTIME_LIFECYCLE_EVENTS,_ as LOCAL_RUNTIME_LEGACY_DEVICE_PROOF_TAG,Z as LOCAL_RUNTIME_DEVICE_PROOF_TAG,c as LOCAL_OPERATION_MAX_BYTES,T as JOBS_START_WAIT_KEY,S as JOBS_START_WAIT,v as HANDS_WORKSPACE_CHECK_KEY,u as HANDS_WORKSPACE_CHECK,M as HANDS_SESSION_GROUP_KEY,L as HANDS_SESSION_GROUP,Q as HANDS_SESSION_CAP_NONE,P as HANDS_SESSION_CAP_KEY,O as HANDS_SESSION_ACCOUNT_KEY,N as HANDS_SESSION_ACCOUNT,x as HANDS_REBIND_KEY,y as HANDS_REBIND_CONTROL,w as HANDS_REBIND,I as HANDS_MODEL_JOBS_EGRESS_KEY,H as HANDS_MODEL_JOBS_EGRESS,E as HANDS_LARGE_ENVIRONMENT_KEY,D as HANDS_LARGE_ENVIRONMENT,K as HANDS_JOBS_USER_KEY,J as HANDS_JOBS_USER,C as HANDS_HEADLESS_BROWSER_KEY,B as HANDS_HEADLESS_BROWSER,o as HANDS_ENVIRONMENT_DELIVER_CONTROL,n as HANDS_ENVIRONMENT_DELIVERY,t as HANDS_ENVIRONMENT_AT_CLAIM_KEY,s as HANDS_ENVIRONMENT_AT_CLAIM,G as HANDS_CONFINEMENT_KEY,F as HANDS_CONFINEMENT,A as HANDS_CLOUD_ACCESS_KEY,z as HANDS_CLOUD_ACCESS,U as AUTOMATION_USER_CHROME,V as AUTOMATION_CLOUD_SESSIONS};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{$i as j,Si as a,Ti as b,Ui as c,Vi as d,Wi as e,Xi as f,Yi as g,Zi as h,_i as i}from"./vm-hands-entry-lite-7k3vp3fe.js";import"./vm-hands-entry-lite-8f3px72v.js";import"./vm-hands-entry-lite-4bgxq9ps.js";import"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-f6714myc.js";import"./vm-hands-entry-lite-05qq23fw.js";import"./vm-hands-entry-lite-hd4a0a6f.js";import"./vm-hands-entry-lite-40nkzw38.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{j as runPermissionsCli,d as reasonIdentity,e as readMacPermissions,f as permissionsSummary,i as parsePermissionsArgs,c as fullDiskAccessTarget,g as formatMacPermissions,h as allowMacPermissions,a as PERMISSIONS_HELP,b as MAC_PERMISSION_IDS};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{$h as V,Ah as u,Bh as v,Ch as w,Dh as x,Eh as y,Fh as z,Gh as A,Hh as B,Ih as C,Jh as D,Kh as E,Lh as F,Mh as G,Nh as H,Oh as I,Ph as J,Qh as K,Rh as L,Sh as M,Th as N,Uh as O,Vh as P,Wh as Q,Xh as R,Yh as S,Zh as T,_h as U,ai as W,bi as X,ci as Y,di as Z,gh as a,hh as b,ih as c,jh as d,kh as e,lh as f,mh as g,nh as h,oh as i,ph as j,qh as k,rh as l,sh as m,th as n,uh as o,vh as p,wh as q,xh as r,yh as s,zh as t}from"./vm-hands-entry-lite-mapxp682.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{w as reasonHandsCloseReason,Y as parseReasonHandsSdkResponse,X as parseReasonHandsSdkRequest,J as parseReasonHandsResult,I as parseReasonHandsRequest,P as parseReasonHandsPtyReceipt,K as parseReasonHandsProgress,O as parseReasonHandsJobResult,N as parseReasonHandsJobRequest,M as parseReasonHandsClaimAck,L as parseReasonHandsClaim,Q as parseReasonHandsCancelRequest,R as parseReasonHandsCancelAck,F as isReasonHandsUuid,D as isReasonHandsRequestId,G as isReasonHandsPtyJobId,E as isReasonHandsGeneration,H as isReasonHandsArtifactSha256,Z as encodeReasonHandsSdkResponse,T as encodeReasonHandsResult,S as encodeReasonHandsRequest,U as encodeReasonHandsProgress,W as encodeReasonHandsClaimAck,V as encodeReasonHandsClaim,y as REASON_HANDS_WORKSPACE_BEFORE_MAX_OUTPUT_CHARS,A as REASON_HANDS_SDK_MAX_QUERY_CHARS,z as REASON_HANDS_SDK_MAX_NAME_CHARS,n as REASON_HANDS_PTY_PROTOCOL_VERSION,q as REASON_HANDS_PTY_MAX_PENDING_INPUT_BYTES,p as REASON_HANDS_PTY_MAX_OUTPUT_BYTES,o as REASON_HANDS_PTY_MAX_INPUT_BYTES,r as REASON_HANDS_PTY_MAX_DIMENSION,s as REASON_HANDS_PTY_CLEANUP_SWEEP_MS,u as REASON_HANDS_PTY_CLEANUP_RECEIPT_MS,t as REASON_HANDS_PTY_ANCHOR_EXIT_MS,a as REASON_HANDS_PROTOCOL_VERSION,f as REASON_HANDS_OUTPUT_TRUNCATED_MARKER,d as REASON_HANDS_MAX_STRUCTURED_INPUT_CHARS,e as REASON_HANDS_MAX_OUTPUT_CHARS,c as REASON_HANDS_MAX_INPUT_CHARS,b as REASON_HANDS_MAX_FRAME_BYTES,g as REASON_HANDS_MAX_ERROR_CHARS,h as REASON_HANDS_JOB_PROTOCOL_VERSION,l as REASON_HANDS_JOB_MAX_RECORDS,k as REASON_HANDS_JOB_MAX_OUTPUT_CHUNKS,j as REASON_HANDS_JOB_MAX_OUTPUT_CHARS,i as REASON_HANDS_JOB_MAX_INPUT_CHARS,B as REASON_HANDS_JOB_ERRORS,m as REASON_HANDS_JOB_CONTROL_MAX_FRAME_BYTES,x as REASON_HANDS_ERROR_CODES,v as REASON_HANDS_CLOSE_CODES,C as HandsProtocolError};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{$d as j,Sd as a,Td as b,Ud as c,Vd as d,Wd as e,Xd as f,Yd as g,Zd as h,_d as i,ae as k,be as l,ce as m,de as n,ee as o,fe as p,ge as q,he as r}from"./vm-hands-entry-lite-r6f6qkw6.js";import"./vm-hands-entry-lite-np1fcr2t.js";import"./vm-hands-entry-lite-q4tcfj61.js";import"./vm-hands-entry-lite-fbpxs065.js";import"./vm-hands-entry-lite-4bgxq9ps.js";import"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import"./vm-hands-entry-lite-f6714myc.js";import"./vm-hands-entry-lite-05qq23fw.js";import"./vm-hands-entry-lite-8gjrr6hg.js";import"./vm-hands-entry-lite-hepppjp0.js";import"./vm-hands-entry-lite-wer0qzxg.js";import"./vm-hands-entry-lite-72nn2b4n.js";export{g as workerServiceRetargetPending,f as workerServiceProgram,m as workerServiceProcessRunning,e as workerServiceLauncher,j as workerServiceDefinitions,n as workerServiceDefinitionCurrent,l as retireLegacyWorkerService,q as retargetWorkerServiceLogs,p as restartWorkerService,r as removeWorkerService,i as isConnectServiceLabel,k as installedWorkerService,o as installWorkerService,c as defaultWorkerServiceHost,h as connectServiceLabel,d as WorkerServiceError,a as WORKER_SERVICE_ENV,b as WORKER_IDENTITY_UNAVAILABLE_CODE};
|
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{a as jq,b as Dq,c as Vq,d as kq,g as Hq,h as zq,m as Aq}from"./vm-hands-entry-lite-32ch1nr1.js";import"./vm-hands-entry-lite-wa261sf8.js";import{y as Fq}from"./vm-hands-entry-lite-h9t84ekh.js";import{A as Wq,K as bq}from"./vm-hands-entry-lite-g5c9ec33.js";import"./vm-hands-entry-lite-mxdztdmq.js";import"./vm-hands-entry-lite-h0y0xv5f.js";import"./vm-hands-entry-lite-tkb2b6x8.js";import"./vm-hands-entry-lite-va3vbvsk.js";import"./vm-hands-entry-lite-yg5h9mhm.js";import"./vm-hands-entry-lite-69ray4x8.js";import"./vm-hands-entry-lite-jcd21jpm.js";import"./vm-hands-entry-lite-swwb5mp2.js";import"./vm-hands-entry-lite-5rkakg10.js";import"./vm-hands-entry-lite-nqvb7a2m.js";import"./vm-hands-entry-lite-jw5y1aa5.js";import"./vm-hands-entry-lite-vr4sva78.js";import"./vm-hands-entry-lite-r6f6qkw6.js";import{ye as Kq}from"./vm-hands-entry-lite-np1fcr2t.js";import"./vm-hands-entry-lite-ky0w7t09.js";import"./vm-hands-entry-lite-q590arx5.js";import"./vm-hands-entry-lite-1sc3wc94.js";import{Pg as xq,Ug as Bq}from"./vm-hands-entry-lite-yqrmr2c8.js";import"./vm-hands-entry-lite-9vf97byd.js";import"./vm-hands-entry-lite-xqve205b.js";import"./vm-hands-entry-lite-mapxp682.js";import"./vm-hands-entry-lite-2nec0vk1.js";import{Ai as s,xi as z,zi as u}from"./vm-hands-entry-lite-q4tcfj61.js";import"./vm-hands-entry-lite-fbpxs065.js";import"./vm-hands-entry-lite-7k3vp3fe.js";import"./vm-hands-entry-lite-8f3px72v.js";import"./vm-hands-entry-lite-4bgxq9ps.js";import{xj as l}from"./vm-hands-entry-lite-hye6r7dy.js";import"./vm-hands-entry-lite-6berk108.js";import{Xj as N}from"./vm-hands-entry-lite-f6714myc.js";import"./vm-hands-entry-lite-05qq23fw.js";import"./vm-hands-entry-lite-hd4a0a6f.js";import{uk as Q}from"./vm-hands-entry-lite-vr38bh6k.js";import"./vm-hands-entry-lite-r2xmr627.js";import"./vm-hands-entry-lite-8gjrr6hg.js";import"./vm-hands-entry-lite-hepppjp0.js";import"./vm-hands-entry-lite-wer0qzxg.js";import"./vm-hands-entry-lite-40nkzw38.js";import{Xk as Gq}from"./vm-hands-entry-lite-72nn2b4n.js";import{createHash as aq,randomBytes as nq}from"crypto";import{readFileSync as eq,realpathSync as Pq,renameSync as q3,unlinkSync as J3,writeFileSync as X3}from"fs";import{dirname as Y3,join as yq}from"path";import{spawnSync as wq}from"child_process";import{accessSync as Lq,constants as fq,existsSync as L,mkdirSync as Sq,readFileSync as hq,renameSync as Cq,writeFileSync as gq}from"fs";import{homedir as mq}from"os";import{delimiter as pq,dirname as dq,join as T}from"path";import{existsSync as Eq,readFileSync as Mq}from"fs";import{join as _q}from"path";var vq=`---
|
|
3
|
-
name: reason
|
|
4
|
-
description: Integrate software with Reason's public REST API using a scoped API key. Use for API clients, CI, service integrations, or cloud coding-session automation.
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# Reason API
|
|
8
|
-
|
|
9
|
-
Reason integrations use the public REST API. Public customer MCP is retired.
|
|
10
|
-
|
|
11
|
-
Base URL: \`https://api.reasonmachines.com/v3\`
|
|
12
|
-
|
|
13
|
-
- API quickstart: \`https://docs.reasonmachines.com/api-quickstart\`
|
|
14
|
-
- Endpoint reference: \`https://docs.reasonmachines.com/api-reference\`
|
|
15
|
-
|
|
16
|
-
## Authentication and scope
|
|
17
|
-
|
|
18
|
-
1. Create a least-privilege \`ara_\` key in Reason Settings \u2192 Developers (the Code
|
|
19
|
-
/ API keys picker) and keep it only in the calling service or CI secret
|
|
20
|
-
manager. Never
|
|
21
|
-
put it in source, prompts, logs, generated files, or a repository
|
|
22
|
-
environment file. A new key from that picker includes the ordinary public
|
|
23
|
-
scopes for session, skill, repo, and org reads.
|
|
24
|
-
2. Send it as \`Authorization: Bearer <api-key>\`. Call \`GET /v3/self\` first
|
|
25
|
-
to resolve the key's organization before reading or mutating resources.
|
|
26
|
-
3. Request only the scopes needed by the integration. Treat secret values as
|
|
27
|
-
write-only and never expose them in API responses or diagnostics.
|
|
28
|
-
4. Use the endpoint reference as the source of truth for request/response
|
|
29
|
-
shapes, pagination, and error handling. Do not recreate an old MCP client,
|
|
30
|
-
route, OAuth flow, or plugin configuration. Do not connect to the retired
|
|
31
|
-
public MCP transport.
|
|
32
|
-
|
|
33
|
-
## Session automation
|
|
34
|
-
|
|
35
|
-
- Create and monitor sessions through the documented \`/v3/organizations/:orgId/
|
|
36
|
-
sessions\` endpoints. Return the session URL or identifier to the caller, then
|
|
37
|
-
poll or stream only as the API reference specifies.
|
|
38
|
-
- Omit \`hands_mode\` for adaptive lazy Hands, or set it to \`brain_only\` when
|
|
39
|
-
physical execution must remain permanently disabled for that Conversation.
|
|
40
|
-
- Keep API work idempotent where the endpoint supports it, and surface failed
|
|
41
|
-
mutations rather than retrying destructive operations blindly.
|
|
42
|
-
- Scope every request to the intended organization and repository. Do not infer
|
|
43
|
-
authority from a repository name or an untrusted task payload.
|
|
44
|
-
`;function m(q){return _q(q,".agents","skills","ara","SKILL.md")}function i(q){let X=m(q);return Eq(X)&&Mq(X,"utf8")===vq}var p=["codex","claude","cursor"],r={codex:"Codex",claude:"Claude Code",cursor:"Cursor"};function uq(q,X=process.env){let J=X.PATH??"",Z=process.platform==="win32"?(X.PATHEXT??".EXE;.CMD;.BAT;.COM").split(";"):[""];for(let Y of J.split(pq)){if(!Y)continue;for(let G of Z)try{return Lq(T(Y,`${q}${G}`),fq.X_OK),!0}catch{}}return!1}function lq(){return{exists:uq,run(q,X,J={}){let Z=J.interactive===!0,Y=wq(q,X,{encoding:"utf8",env:process.env,stdio:Z?"inherit":"pipe"});return{status:Y.status??1,stdout:Z?"":Y.stdout??"",stderr:Z?Y.error?.message??"":`${Y.stderr??""}${Y.error?`${Y.error.message}
|
|
45
|
-
`:""}`}}}}function O(q){return`${q.stdout}
|
|
46
|
-
${q.stderr}`}function k(q){return q.status===0}function R(q,X,J,Z={}){let Y=q.run(X,J,Z);if(k(Y))return Y;let G=O(Y).trim();throw Error(`${X} ${J.join(" ")} failed${G?`: ${G}`:` with exit code ${Y.status}`}`)}function cq(q=process.env){return s(z({env:q}))}function d(q,X){return q.split(/\s+/).some((J)=>a(J,X))}function w(q){return T(q,".cursor","mcp.json")}function t(q){if(!L(q))return{};try{let X=JSON.parse(hq(q,"utf8"));if(!X||typeof X!=="object"||Array.isArray(X))throw Error("top-level value must be an object");return X}catch(X){let J=X instanceof Error?X.message:String(X);throw Error(`Cursor MCP config at ${q} is invalid; refusing to overwrite it (${J})`)}}function oq(q,X){Sq(dq(q),{recursive:!0,mode:448});let J=`${q}.ara-${process.pid}.tmp`;gq(J,`${JSON.stringify(X,null,2)}
|
|
47
|
-
`,{mode:384}),Cq(J,q)}function a(q,X){if(typeof q!=="string")return!1;if(q===X)return!0;try{let J=new URL(q);return["https://api.ara.so","https://api-staging.ara.so","https://api.reasonmachines.ai","https://staging-api.reasonmachines.ai","https://api.reasonmachines.com","https://staging-api.reasonmachines.com"].includes(J.origin)&&!J.username&&!J.password&&J.pathname==="/mcp/ara"&&!J.search&&!J.hash}catch{return!1}}function iq(q,X){let J=q.mcpServers?.ara;return Boolean(J&&typeof J==="object"&&!Array.isArray(J)&&a(J.url,X))}class f{runner;home;mcpUrl;constructor(q=lq(),X=mq(),J=cq()){this.runner=q;this.home=X;this.mcpUrl=J}isAvailable(q){if(q==="codex")return this.runner.exists("codex");if(q==="claude")return this.runner.exists("claude");return this.runner.exists("cursor")||L("/Applications/Cursor.app")||L(T(this.home,"Applications","Cursor.app"))||L(w(this.home))}availableClients(){return p.filter((q)=>this.isAvailable(q))}installationPath(q){if(q==="cursor")return w(this.home);if(q==="codex")return T(this.home,".codex","plugins","cache","ara");return T(this.home,".claude","plugins","cache","ara")}sharedSkillStatus(){return{installed:i(this.home),path:m(this.home)}}status(q){let X=r[q];if(!this.isAvailable(q))return{id:q,label:X,available:!1,installed:!1,connection:null,detail:"Client not detected",legacyInstallations:[]};if(q==="cursor"){let B=w(this.home),V=iq(t(B),this.mcpUrl);return{id:q,label:X,available:!0,installed:V,connection:V?"configured":null,detail:V?`Retired Reason MCP configuration in ${B}`:`No retired Reason MCP configuration in ${B}`,legacyInstallations:[]}}if(q==="codex"){let B=this.runner.run("codex",["plugin","list"]);if(!(k(B)&&O(B).includes("ara@ara")))return{id:q,label:X,available:!0,installed:!1,connection:null,detail:"No retired Reason plugin installed",legacyInstallations:[]};let P=this.runner.run("codex",["mcp","list"]),x=O(P).split(/\r?\n/).find((M)=>M.trimStart().startsWith("ara ")&&d(M,this.mcpUrl)),h=k(P)&&Boolean(x),E=!k(P)?"error":x?.includes("Not logged in")?"not_logged_in":x?.includes("OAuth")?"oauth":x?"configured":"unknown";return{id:q,label:X,available:!0,installed:h,connection:E,detail:x?.trim()||"The retired Reason plugin is installed but has no verified retired MCP registration",legacyInstallations:[]}}let J=this.runner.run("claude",["plugin","list"]),Z=O(J),Y=k(J)&&Z.includes("ara@ara"),G=k(J)&&Z.includes("ara-handoff@ara");if(!Y&&!G)return{id:q,label:X,available:!0,installed:!1,connection:null,detail:"No retired Reason plugin installed",legacyInstallations:[]};let b=this.runner.run("claude",["mcp","list"]),j=O(b),F=j.split(/\r?\n/).find((B)=>B.includes("plugin:ara:ara")&&d(B,this.mcpUrl)),K=j.split(/\r?\n/).find((B)=>B.includes("plugin:ara-handoff:ara")&&d(B,this.mcpUrl)),U=k(b)&&Boolean(F),D=k(b)&&K?["ara-handoff@ara"]:[],S=!k(b)?"error":F?.includes("Connected")?"connected":F?.includes("Failed")?"error":F?"configured":"unknown";return{id:q,label:X,available:!0,installed:U,connection:S,detail:F?.trim()||"The retired Reason plugin is installed but has no verified retired MCP registration",legacyInstallations:D}}statuses(){return p.map((q)=>this.status(q))}logout(q){let X=this.status(q);if(!X.available||!X.installed)return`${X.label}: not connected`;if(q==="cursor")return this.uninstall("cursor").replace("removed retired Reason","signed out and removed retired Reason");if(q==="codex")return R(this.runner,"codex",["mcp","logout","ara"]),"Codex: signed out of Reason";return R(this.runner,"claude",["mcp","logout","plugin:ara:ara"]),"Claude Code: signed out of Reason"}uninstall(q){let X=this.status(q);if(!X.available||!X.installed)return`${X.label}: Reason is not installed`;if(q==="cursor"){let J=w(this.home),Z=t(J),Y={...Z.mcpServers??{}};return delete Y.ara,Z.mcpServers=Y,oq(J,Z),`Cursor: removed retired Reason MCP from ${J}`}if(q==="codex")return R(this.runner,"codex",["plugin","remove","ara@ara"]),"Codex: removed retired ara@ara";return R(this.runner,"claude",["plugin","uninstall","ara@ara","--scope","user"]),"Claude Code: removed retired ara@ara"}removeLegacyClaudePlugin(){if(!this.runner.exists("claude"))return"Claude Code: not installed";if(!this.status("claude").legacyInstallations.includes("ara-handoff@ara"))return"Claude Code: no legacy Reason plugin found";return R(this.runner,"claude",["plugin","uninstall","ara-handoff@ara","--scope","user"]),"Claude Code: removed obsolete ara-handoff@ara"}removeRetiredInstallations(){let q=[],X=[];for(let J of p){let Z;try{Z=this.status(J)}catch(Y){X.push(`${r[J]}: ${Y instanceof Error?Y.message:String(Y)}`);continue}if(Z.installed){if(J!=="cursor")try{q.push(this.logout(J))}catch(Y){X.push(`${Z.label}: ${Y instanceof Error?Y.message:String(Y)}`)}try{q.push(this.uninstall(J))}catch(Y){X.push(`${Z.label}: ${Y instanceof Error?Y.message:String(Y)}`)}}if(J==="claude"&&Z.legacyInstallations.includes("ara-handoff@ara"))try{q.push(this.removeLegacyClaudePlugin())}catch(Y){X.push(`${Z.label}: ${Y instanceof Error?Y.message:String(Y)}`)}}if(q.length===0&&X.length===0)q.push("No retired Reason MCP configuration found.");return{messages:q,failures:X}}}function n(q){return`claude mcp add --transport http reason ${q}`}function e(q){return`codex mcp add reason --url ${q}
|
|
48
|
-
codex mcp login reason`}var N3=n("https://mcp.reasonmachines.com/mcp"),I3=e("https://mcp.reasonmachines.com/mcp"),R3=`https://claude.ai/settings/connectors?add=custom&url=${encodeURIComponent("https://mcp.reasonmachines.com/mcp")}`,O3=`https://cursor.com/install-mcp?name=reason&config=${encodeURIComponent(btoa(JSON.stringify({url:"https://mcp.reasonmachines.com/mcp"})))}`;var rq="https://github.com/reason-machines/reason-plugins",v3=`Connect a coding agent to Reason over MCP
|
|
49
|
-
|
|
50
|
-
Usage:
|
|
51
|
-
reason mcp Show how to connect Claude Code, Codex, or another MCP client
|
|
52
|
-
reason mcp uninstall Remove only this machine's registrations of the earlier, retired server
|
|
53
|
-
|
|
54
|
-
Plugins for Claude Code and Codex: ${rq}
|
|
55
|
-
`;function qq(q){if(!q.available)return"not detected";if(q.installed||q.legacyInstallations.length>0)return"retired configuration";return"not installed"}function tq(q,X){let J=X.toLowerCase();if(q==="codex")return J.includes("codex");if(q==="claude")return J.includes("claude");return J.includes("cursor")}function Jq(q,X){return(X.mcp_connections??[]).filter((Z)=>tq(q.id,Z.client_name)).flatMap((Z)=>Z.last_used_at?[Z.last_used_at]:[]).sort().at(-1)??null}function Xq(q,X=new Date){if(!q)return"never";let J=Date.parse(q);if(!Number.isFinite(J))return"never";let Z=Math.max(0,Math.floor((X.getTime()-J)/1000));if(Z<45)return"just now";let Y=Math.floor(Z/60);if(Y<60)return`${Y} ${Y===1?"minute":"minutes"} ago`;let G=Math.floor(Y/60);if(G<24)return`${G} ${G===1?"hour":"hours"} ago`;let b=Math.floor(G/24);return`${b} ${b===1?"day":"days"} ago`}function Yq(q){let X=q.name?.trim(),J=q.email?.trim();if(X&&J)return`${X} (${J})`;return X||J||q.id||"Reason user"}function Zq(q){let X=q.name?.trim(),J=q.slug?.trim();if(X&&J)return`${X} (${J})`;return X||J||q.id}var sq=Q.enum(["granted","not_granted","unknown"]),$q=Q.object({status:sq,checkedAt:Q.number().finite(),executablePath:Q.string().min(1)});var Z3=`Reason status
|
|
56
|
-
|
|
57
|
-
Usage:
|
|
58
|
-
reason status [--json]
|
|
59
|
-
|
|
60
|
-
Show the installed version, signed-in account and organization, this
|
|
61
|
-
computer's connection (\`reason connect\`) and the workspaces it serves, any
|
|
62
|
-
retired MCP configuration that can be cleaned up, and automatic updates.
|
|
63
|
-
`,$3=5000,G3=300000,Q3=Q.object({version:Q.literal(1),key:Q.string(),at:Q.number(),self:Q.object({principal_type:Q.string(),user_id:Q.string().optional(),user_name:Q.string().nullish(),email:Q.string().nullish(),org_id:Q.string(),organization_name:Q.string().nullish(),organization_slug:Q.string().nullish(),mcp_connections:Q.array(Q.object({client_id:Q.string(),client_name:Q.string(),last_used_at:Q.string().nullable()})).optional()})}),Nq=(q)=>`${q.apiOrigin}
|
|
64
|
-
${aq("sha256").update(q.accessToken).digest("hex")}`;function x3(q,X,J){try{let Z=Q3.safeParse(JSON.parse(eq(q,"utf8")));if(!Z.success||Z.data.key!==Nq(X))return null;let Y=J-Z.data.at;return Y>=0&&Y<G3?Z.data.self:null}catch{return null}}function B3(q,X,J,Z){let Y=`${q}.${process.pid}.${nq(6).toString("hex")}.tmp`;try{let G={version:1,key:Nq(X),at:Z,self:J};X3(Y,`${JSON.stringify(G)}
|
|
65
|
-
`,{mode:384,flag:"wx"}),q3(Y,q)}catch{try{J3(Y)}catch{}}}var W3=30000;function b3(q,X=Date.now(),J=null){let Z=Bq(q),Y=(()=>{if(Z?.state!=="connected"&&Z?.state!=="starting")return!1;try{return process.kill(Z.pid,0),!0}catch{return!1}})(),G=Y&&Z?.state==="connected",b=(K)=>G&&X-K>=0&&X-K<W3,j=$q.safeParse(Z?.fullDiskAccess),F=xq(Z,J,X);return{...F?{permission_recovery:F}:{},full_disk_access:j.success&&b(j.data.checkedAt)?j.data.status:"unknown",keep_awake:{enabled:Vq(q)==="battery_and_ac",holding:Z?.idleSleepHold===!0&&b(Date.parse(Z.lastHeartbeatAt??""))},executable:Y&&j.success?j.data.executablePath:null}}function F3(q=z()){if(process.platform!=="darwin")return null;let X=kq(yq(Hq(Pq(l()),q),"worker.json"));return X?b3(jq(X).daemon,Date.now(),Dq(X)):null}var Qq={connected:"connected",starting:"starting",reconnecting:"reconnecting",stopping:"stopping",not_running:"not running",removed:"removed from Reason (run `reason connect` to connect it again)"};async function Y1(q,X={}){let J=X.io??{stdout:process.stdout,stderr:process.stderr};if(q.includes("--help")||q.includes("-h"))return J.stdout.write(Z3),0;if(q.some((G)=>G!=="--json"))return J.stderr.write(`Usage: reason status [--json]
|
|
66
|
-
`),1;let Z=new AbortController,Y=setTimeout(()=>Z.abort(Error("timed out reading the account")),$3);try{let G=X.now?.()??new Date,b=performance.now(),j=b,F=()=>{let $=performance.now(),H=Math.round($-j);return j=$,H},K=null,U=($)=>{return K=$ instanceof Error?$.message:String($),null},D=await Fq(X,Z.signal).catch(U),S=F(),B=D?.credentialKind==="api_key",V=D&&!B?yq(Y3(Wq(X.env??process.env)),"status-account.json"):null,P=D&&V&&q.includes("--json")?x3(V,D,G.getTime()):null,x=P??(D?await(X.getSelf??(($,H)=>new bq($).self(H)))(D,Z.signal).catch(U):null);if(D&&x&&!P&&V)B3(V,D,x,G.getTime());let h=F(),E=X.manager??new f,M=q.includes("--json")?[]:E.statuses(),_=(X.loadReceipt??Kq)(),v=await(X.readConnection??(()=>Aq({channel:X.channel})))().catch(()=>null),A=null;try{if(v)A=(X.readConnectionMacState??(()=>F3(X.channel??z())))()}catch{}let W=v&&A?{...v,...A}:v,C=(()=>{try{return(X.readDisconnected??(()=>zq(Pq(l()),X.channel??z())))()}catch{return!1}})(),Iq=F(),c=x?{id:x.org_id,name:x.organization_name??null,slug:x.organization_slug??null}:null,I=x?{id:x.user_id??null,name:(B?x.service_user_name:x.user_name)??null,email:x.email??null,credential:B?"api_key":"login"}:null,g=X.channel??z(),y={version:N,channel:g,api_origin:D?.apiOrigin??u(g),account:I,account_error:K,organization:c,mcp:M.map(($)=>({client:$.id,label:$.label,status:qq($),installed_at:$.installed?E.installationPath($.id):null,last_used_at:x?Jq($,x):null})),connection:W,disconnected:C,installation:_?{background_mode:_.background_mode,automatic_updates:_.background_mode!=="cli_only",future_device_consent:_.device_consent?.decision??"disabled"}:null,timings_ms:{process:Math.round(b),credentials:S,account:h,local:Iq,total:Math.round(performance.now()-b)}};if(q.includes("--json"))return J.stdout.write(`${JSON.stringify(y,null,2)}
|
|
67
|
-
`),0;if(g==="staging")J.stdout.write(`Reason ${N} \xB7 channel: STAGING
|
|
68
|
-
`),J.stdout.write(`API: ${y.api_origin}
|
|
69
|
-
`);else J.stdout.write(`Reason ${N}
|
|
70
|
-
`);if(I)J.stdout.write(B?`Account: API key (REASON_API_KEY)${I.name?`: ${I.name}`:""}
|
|
71
|
-
`:`Account: ${Yq(I)}
|
|
72
|
-
`),J.stdout.write(`Organization: ${Zq(c)}
|
|
73
|
-
`);else if(K)J.stdout.write(`Account: unavailable (${K})
|
|
74
|
-
`);else J.stdout.write(`Account: signed out
|
|
75
|
-
`),J.stdout.write(`Organization: none
|
|
76
|
-
`);if(J.stdout.write(`
|
|
77
|
-
This computer
|
|
78
|
-
`),!W)J.stdout.write(C?"Disconnected. Run `reason connect` to connect it again.\n":"Not connected. Run `reason connect` to run your Sessions here.\n");else{if(J.stdout.write(`Connection: ${Qq[W.state]} (${W.name})${C?", disconnected (run `reason connect` to connect it again)":""}
|
|
79
|
-
`),W.version)J.stdout.write(`Version: ${W.version}${W.version===N?"":` (${N} is installed; \`reason connect\` restarts it on that)`}
|
|
80
|
-
`);if(J.stdout.write(`Folder: ${W.folder}
|
|
81
|
-
`),J.stdout.write(`Sessions: ${W.sessions_running===null?"":`${W.sessions_running} running, `}${W.sessions_max===null?"every Session you start":W.sessions_max===1?"one at a time":`up to ${W.sessions_max} at once`}
|
|
82
|
-
`),A){let $=A,H=await(X.readPermissionsSummary??(async()=>{let{permissionsSummary:Rq,readMacPermissions:Oq,reasonIdentity:Tq}=await import("./permissions-92a6yh7t.js"),{macScreenStatus:Uq}=await import("./local-display-mac-jzc0g5ge.js");return Rq(await Oq({identity:()=>Tq(),grants:Uq,worker:async()=>$}))}))().catch(()=>null);if(H)J.stdout.write(`${H}
|
|
83
|
-
`);J.stdout.write(`Keep awake: ${A.keep_awake.enabled?"on":"off"}${A.keep_awake.holding?" (holding)":""}
|
|
84
|
-
`)}if(W.service)J.stdout.write(`Logs: ${W.service.logs}
|
|
85
|
-
`);for(let $ of W.workspaces??[]){let H=$.state==="removed"?"removed from that workspace":$.blocked?"offline (this computer is outside that workspace's allowed networks)":$.device_id?Qq[$.state]:"connecting";J.stdout.write(`Also in workspace ${$.name??$.organization_id}${$.account?" (another Reason account's)":""}: ${H}
|
|
86
|
-
`)}if(W.workspaces_off==="sign_in")J.stdout.write("Other workspaces: off. This computer's sign-in is not one the Reason app or the setup command\n Reason shows you made for it (or that sign-in ended, or it is in use on another computer), so it is\n connected in one workspace only. Run the setup command from Reason here (it ends in --pair CODE);\n if this computer was connected before that, run `reason disconnect` and `reason connect` once.\n")}let o=y.mcp.filter(($)=>$.installed_at||$.status!=="not installed");if(o.length>0)J.stdout.write(`
|
|
87
|
-
Retired MCP configuration
|
|
88
|
-
`);for(let $ of o)if(J.stdout.write(`${$.label}: ${$.status}
|
|
89
|
-
`),$.installed_at)J.stdout.write(` Installed: ${$.installed_at}
|
|
90
|
-
`),J.stdout.write(` Last used: ${Xq($.last_used_at,G)}
|
|
91
|
-
`);if(y.mcp.some(($)=>$.status==="retired configuration"))J.stdout.write("Run `reason mcp uninstall` to remove only the retired Reason MCP registrations.\n");if(J.stdout.write(`
|
|
92
|
-
Background access
|
|
93
|
-
`),!y.installation)J.stdout.write(`Not managed by the Reason installer
|
|
94
|
-
`);else J.stdout.write(`Automatic updates: ${y.installation.automatic_updates?"enabled":"disabled"}
|
|
95
|
-
`);return 0}catch(G){return J.stderr.write(`Reason status: ${G instanceof Error?G.message:String(G)}
|
|
96
|
-
`),1}finally{clearTimeout(Y)}}export{b3 as workerMacState,Y1 as runStatusCli,F3 as connectionMacState,Z3 as STATUS_HELP};
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
var r={name:"github-native-engineer-device-worker-production",version:"0.2.407",private:!0,type:"module",engines:{node:">=22",bun:">=1.3.0"},workspaces:["../../packages/runtime-distribution"],dependencies:{"@anthropic-ai/sandbox-runtime":"^0.0.73","@earendil-works/pi-tui":"1.0.0","@modelcontextprotocol/sdk":"^1.29.0","@reason/runtime-distribution":"workspace:*","playwright-core":"1.60.0",zod:"^4.4.3"},overrides:{"@hono/node-server":"^1.19.15","@earendil-works/pi-agent-core":"1.0.0","@earendil-works/pi-ai":"1.0.0","@earendil-works/pi-coding-agent":"1.0.0","@earendil-works/chord":"1.0.0","@earendil-works/pi-codemode":"1.0.0","@earendil-works/pi-mcp":"1.0.0","@earendil-works/pi-telemetry":"1.0.0","@earendil-works/pi-tui":"1.0.0","brace-expansion":"2.1.7",axios:"^1.20.0","basic-ftp":"^6.2.1","@grpc/grpc-js":"^1.14.5",browserslist:"^4.28.8","engine.io":"^6.6.7","fast-uri":"^3.1.8",hono:"^4.13.7","ip-address":"^10.7.1",nanoid:"^3.3.18",dompurify:"^3.4.17",postcss:"^8.5.23",qs:"^6.16.0","shell-quote":"^1.11.0","socket.io-parser":"^4.2.7",tmp:"^0.2.7",toml:"^4.2.0",undici:"^8.10.2",ws:"^8.21.0","js-yaml":"^4.3.2","@modelcontextprotocol/sdk":"^1.31.0","proxy-addr":"^2.0.8","source-map-js":"^1.2.2"}};
|
|
3
|
-
export{r as $j};
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Xg as p}from"./vm-hands-entry-lite-yqrmr2c8.js";import{ch as h}from"./vm-hands-entry-lite-xqve205b.js";import{kh as s}from"./vm-hands-entry-lite-mapxp682.js";import{yj as d}from"./vm-hands-entry-lite-hye6r7dy.js";import{Lj as i}from"./vm-hands-entry-lite-6berk108.js";import{Pk as P}from"./vm-hands-entry-lite-hepppjp0.js";import{Rk as V}from"./vm-hands-entry-lite-40nkzw38.js";import{existsSync as U,realpathSync as l,statSync as e}from"fs";import{platform as f}from"os";import{isAbsolute as r,sep as zz}from"path";import{existsSync as n}from"fs";import{createRequire as t}from"module";var E=P(h)(()=>t(import.meta.url)("bun:ffi"),n);function m(){return process.platform==="win32"&&typeof globalThis.Bun<"u"&&E.available()}function w(z=process.env){return E.defaultShell(z)}function k(z){return E.shellArgs(z)}function v(z){let H=E.spawn({...z,env:z.environment});return H.exited.then(()=>H.close()),{write:(Q)=>H.write(Q),resize:(Q,J)=>H.resize(Q,J),kill:()=>H.close(),exited:H.exited}}var Hz=43200000,y=s,Jz=4,Qz=/^[A-Za-z0-9._:-]{1,160}$/,Vz=1000;function u(z){return Boolean(z)&&typeof z==="object"&&!Array.isArray(z)}function g(z,H){if(typeof z!=="number"||!Number.isFinite(z)||z<=0)return H;return Math.min(Vz,Math.max(1,Math.floor(z)))}function Zz(z,H=Date.now()){let Q=["relay_url","session_id","expires_at"],J=new Set([...Q,"cols","rows","cwd","workspace"]);if(!u(z)||Q.some((C)=>!(C in z))||Object.keys(z).some((C)=>!J.has(C)))throw new V("invalid_pty_request","Reason terminal request is malformed.");let{relay_url:N,session_id:Y,expires_at:R}=z;if(typeof N!=="string")throw new V("invalid_pty_request","Reason terminal relay URL is missing.");let K;try{K=new URL(N)}catch{throw new V("invalid_pty_request","Reason terminal relay URL is invalid.")}if(K.protocol!=="wss:"&&K.protocol!=="ws:"||K.username||K.password)throw new V("invalid_pty_request","Reason terminal relay URL is invalid.");if(typeof Y!=="string"||!Qz.test(Y))throw new V("invalid_pty_request","Reason terminal session identity is invalid.");let D=typeof R==="string"?Date.parse(R):Number.NaN;if(!Number.isFinite(D)||D<=H)throw new V("invalid_pty_request","Reason terminal session has already expired.");if(z.cwd!==void 0&&typeof z.cwd!=="string")throw new V("invalid_pty_request","Reason terminal working directory is invalid.");let j=z.workspace===void 0?void 0:i(z.workspace);if(j===null||j&&z.cwd!==void 0)throw new V("invalid_pty_request","Reason terminal workspace is invalid.");return{relay_url:N,session_id:Y,expires_at:new Date(Math.min(D,H+Hz)).toISOString(),cols:g(z.cols,80),rows:g(z.rows,24),...z.cwd===void 0?{}:{cwd:z.cwd},...j?{workspace:j}:{}}}function $z(z,H){if(f()==="win32")[z,H]=[z.toLowerCase(),H.toLowerCase()];return H===z||H.startsWith(z+zz)}function c(z,H){if(H===void 0)return z;if(!r(H))throw new V("pty_cwd_invalid","Reason terminal working directory must be absolute.");let Q;try{Q=l(H)}catch{throw new V("pty_cwd_invalid","Reason terminal working directory does not exist.")}if(!$z(z,Q))throw new V("pty_cwd_outside_root","Reason terminal working directory escapes the granted root.");if(!e(Q).isDirectory())throw new V("pty_cwd_invalid","Reason terminal working directory is not a directory.");return Q}function jz(z=process.env){if(f()==="win32")return w(z);let H=z.SHELL;if(H&&r(H)&&U(H))return H;for(let Q of f()==="darwin"?["/bin/zsh","/bin/bash","/bin/sh"]:["/bin/bash","/bin/sh"])if(U(Q))return Q;return"/bin/sh"}function Gz(){let z=globalThis.Bun;if(!z)throw new V("pty_unavailable","Reason terminals require the Bun runtime.");return z.spawn}function Sz(){if(f()==="win32")return m();return typeof globalThis.Bun<"u"}var Nz=(z)=>{if(f()==="win32")try{return v({...z,file:z.shell,args:k(z.shell),environment:{...z.environment,TERM:"xterm-256color"}})}catch{throw new V("pty_unavailable","Reason could not allocate a pseudo-terminal.")}let H=Gz()({cmd:[z.shell,"-i","-l"],cwd:z.cwd,env:{...z.environment,TERM:"xterm-256color"},terminal:{cols:z.cols,rows:z.rows,data:(J,N)=>{z.onData(N)}}}),Q=H.terminal;if(!Q){try{H.kill()}catch{}throw new V("pty_unavailable","Reason could not allocate a pseudo-terminal.")}return{write:(J)=>Q.write(J),resize:(J,N)=>Q.resize(J,N),kill:()=>{try{H.kill()}catch{}},exited:H.exited.then((J)=>typeof J==="number"?J:null,()=>null)}},Wz=(z,H)=>{return H===void 0?new WebSocket(z):new WebSocket(z,{proxy:H})},M=new Set;function Kz(z){if(M.size>=Jz||M.has(z))return null;M.add(z);let H=!1;return()=>{if(H)return;H=!0,M.delete(z)}}async function Tz(z,H={}){let Q=H.now??Date.now,J=Zz(z.payload,Q()),N=Kz(z.operationId);if(!N)throw new V("pty_slot_busy","This Reason Device already runs the maximum number of terminals.");let Y=Q(),R,K,D;try{let j=J.workspace?d(z.root,J.workspace):void 0;R=j?c(U(j.boundary)?l(j.boundary):j.boundary,j.path):c(z.root,J.cwd),K=H.environment??process.env,D=H.shellPath??jz(K)}catch(j){throw N(),j}return await new Promise((j,C)=>{let F=null,$=null,I=!1,B=!1,X=!1,_=null,b=0,x=0,O=[],S=0,T=null,G=(Z)=>{if(X)return;if(X=!0,T)clearTimeout(T);z.signal.removeEventListener("abort",A);try{F?.kill()}catch{}try{$?.close(1000,"pty_session_over")}catch{}if(N(),Z.kind==="rejected"){C(Z.error);return}let W={reason:Z.reason,exit_code:_,output_bytes:b,input_bytes:x,duration_ms:Math.max(0,Q()-Y)};z.emitEvent("pty.stopped",{...W}).catch(()=>{return}),j({...W})},A=()=>{let Z=z.signal.reason;G({kind:"rejected",error:Z instanceof V?Z:new V("cancelled","Reason closed the terminal session.")})};if(z.signal.aborted){A();return}z.signal.addEventListener("abort",A,{once:!0}),T=setTimeout(()=>G({kind:"resolved",reason:"session_expired"}),Math.max(1,Date.parse(J.expires_at)-Q()));let a=(Z)=>{if(b+=Z.byteLength,!I||!$){if(O.push(Z),S+=Z.byteLength,S>y)G({kind:"resolved",reason:"output_backpressure"});return}try{$.send(Z)}catch{G({kind:"resolved",reason:"relay_closed"});return}if($.bufferedAmount>y)G({kind:"resolved",reason:"output_backpressure"})};try{F=(H.spawnPty??Nz)({shell:D,args:["-i","-l"],cwd:R,cols:J.cols,rows:J.rows,environment:K,onData:(Z)=>{if(!X)a(Z)}})}catch(Z){G({kind:"rejected",error:Z instanceof V?Z:new V("pty_spawn_failed","Reason could not start the terminal shell.")});return}F.exited.then((Z)=>{if(X)return;if(_=Z,I&&$)try{$.send(JSON.stringify({t:"exit",code:Z}))}catch{}G({kind:"resolved",reason:"shell_exited"})});let o=(H.loadProxy??p)()?.url;try{$=(H.connect??Wz)(J.relay_url,o)}catch{G({kind:"rejected",error:new V("pty_relay_unavailable","Reason could not reach the terminal relay.")});return}$.binaryType="arraybuffer",$.onopen=()=>{if(X||!$)return;I=!0;try{$.send(JSON.stringify({t:"open",cols:J.cols,rows:J.rows}));for(let Z of O.splice(0))$.send(Z);S=0}catch{G({kind:"resolved",reason:"relay_closed"});return}B=!0,z.emitEvent("pty.ready",{session_id:J.session_id,cols:J.cols,rows:J.rows}).catch(()=>{return})},$.onmessage=(Z)=>{if(X||!F)return;let W=Z.data;if(typeof W==="string"){let L;try{L=JSON.parse(W)}catch{return}if(!u(L))return;if(L.t==="resize"){try{F.resize(g(L.cols,J.cols),g(L.rows,J.rows))}catch{}return}if(L.t==="close")G({kind:"resolved",reason:"client_closed"});return}let q=W instanceof ArrayBuffer?new Uint8Array(W):ArrayBuffer.isView(W)?new Uint8Array(W.buffer,W.byteOffset,W.byteLength):null;if(!q||q.byteLength===0)return;x+=q.byteLength;try{F.write(q)}catch{}},$.onclose=()=>{if(X)return;if(!B){G({kind:"rejected",error:new V("pty_relay_unavailable","Reason could not reach the terminal relay.")});return}G({kind:"resolved",reason:"relay_closed"})},$.onerror=()=>{if(X||B)return;G({kind:"rejected",error:new V("pty_relay_unavailable","Reason could not reach the terminal relay.")})}})}
|
|
3
|
-
export{m as xg,Hz as yg,y as zg,Jz as Ag,Zz as Bg,c as Cg,jz as Dg,Sz as Eg,Nz as Fg,Wz as Gg,Tz as Hg};
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{createHash as f,createPublicKey as V,verify as G}from"crypto";var Y="libara_device_keychain.dylib",H="libreason_device_keychain.dylib",k=1,x=2,h=536870912,R=262144;var U=["darwin-arm64","darwin-x64"];class J extends Error{code;constructor(z,F){super(F);this.code=z;this.name="ManagedRuntimeError"}}var C=/^\d+\.\d+\.\d+(?:-[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/,N=/^[a-f0-9]{64}$/;function X(z){return Boolean(z)&&typeof z==="object"&&!Array.isArray(z)}function $(z,F,Q=[]){let Z=new Set([...F,...Q]);return F.every((W)=>(W in z))&&Object.keys(z).every((W)=>Z.has(W))}function B(z){return typeof z==="string"&&C.test(z)}function O(z){return typeof z==="string"&&!Number.isNaN(Date.parse(z))&&new Date(z).toISOString()===z}function I(z){return U.includes(z)}function c(z,F){if(!B(z)||!I(F))throw new J("invalid_release_asset","Invalid managed runtime release asset.")}function K(z,F){return c(z,F),`reason-runtime-v${z}-${F}`}function g(z,F){return`${K(z,F)}-${H}`}var o="managed-runtime-identity.json",D="reason-macos-background-identity-v1";function q(z){if(z===null)return"null";if(typeof z==="string"||typeof z==="boolean")return JSON.stringify(z);if(typeof z==="number"){if(!Number.isFinite(z))throw new J("invalid_manifest","Manifest numbers must be finite.");return JSON.stringify(z)}if(Array.isArray(z))return`[${z.map((F)=>q(F)).join(",")}]`;if(X(z))return`{${Object.keys(z).sort().map((F)=>`${JSON.stringify(F)}:${q(z[F])}`).join(",")}}`;throw new J("invalid_manifest","Manifest contains an unsupported value.")}function j(z){if(!X(z)||!$(z,["url","sha256","size_bytes"])||typeof z.url!=="string"||typeof z.sha256!=="string"||!N.test(z.sha256)||typeof z.size_bytes!=="number"||!Number.isSafeInteger(z.size_bytes)||z.size_bytes<=0||z.size_bytes>h)throw new J("invalid_manifest","Manifest contains an invalid runtime artifact.");let F;try{F=new URL(z.url)}catch{throw new J("invalid_manifest","Runtime artifact URL is invalid.")}if(F.protocol!=="https:"||F.username||F.password||F.hash)throw new J("invalid_manifest","Runtime artifact URL must be an HTTPS URL without credentials or a fragment.");return{url:F.toString(),sha256:z.sha256,size_bytes:z.size_bytes}}function b(z){if(!X(z)||!$(z,["broker","credential_library"]))throw new J("invalid_manifest","Manifest must bind the broker and credential library as one runtime.");return{broker:j(z.broker),credential_library:j(z.credential_library)}}function _(z){if(!X(z)||!$(z,["schema_version","version","published_at","artifacts"])||z.schema_version!==x||!B(z.version)||!O(z.published_at)||!X(z.artifacts)||!$(z.artifacts,[...U]))throw new J("invalid_manifest","Managed Reason runtime manifest is invalid.");return{schema_version:x,version:z.version,published_at:z.published_at,artifacts:{"darwin-arm64":b(z.artifacts["darwin-arm64"]),"darwin-x64":b(z.artifacts["darwin-x64"])}}}function M(z){if(!X(z)||!$(z,["schema_version","version","published_at","artifacts"])||z.schema_version!==k||!B(z.version)||!O(z.published_at)||!X(z.artifacts)||!$(z.artifacts,[...U]))throw new J("invalid_manifest","Legacy managed runtime manifest is invalid.");return{schema_version:k,version:z.version,published_at:z.published_at,artifacts:{"darwin-arm64":j(z.artifacts["darwin-arm64"]),"darwin-x64":j(z.artifacts["darwin-x64"])}}}function A(z){if(!X(z)||!$(z,["schema","version","published_at","artifacts"])||z.schema!==D||!B(z.version)||!O(z.published_at)||!X(z.artifacts)||!$(z.artifacts,[...U]))throw new J("invalid_manifest","Reason background identity manifest is invalid.");return{schema:D,version:z.version,published_at:z.published_at,artifacts:{"darwin-arm64":j(z.artifacts["darwin-arm64"]),"darwin-x64":j(z.artifacts["darwin-x64"])}}}function S(z){if(typeof z!=="string"||!/^[A-Za-z0-9+/]+={0,2}$/.test(z))throw new J("invalid_signature","Runtime manifest signature is invalid.");let F=Buffer.from(z,"base64");if(F.length!==64||F.toString("base64")!==z)throw new J("invalid_signature","Runtime manifest signature is invalid.");return F}function L(z){let F=z;if(typeof z==="string")try{F=JSON.parse(z)}catch{throw new J("invalid_manifest","Managed Reason runtime manifest is not valid JSON.")}if(!X(F)||!$(F,["key_id","manifest","signature"])||typeof F.key_id!=="string"||!/^[A-Za-z0-9._-]{1,80}$/.test(F.key_id)||typeof F.signature!=="string")throw new J("invalid_manifest","Signed managed Reason runtime manifest is invalid.");return F}function E(z,F){let Q=L(z),Z=F[Q.key_id];if(!Z)throw new J("untrusted_key","Runtime manifest was signed by an unknown key.");let W=_(Q.manifest),w=S(Q.signature),P=!1;try{P=G(null,Buffer.from(q(W)),V(Z),w)}catch{throw new J("invalid_signature","Runtime manifest signature could not be verified.")}if(!P)throw new J("invalid_signature","Runtime manifest signature did not match.");return{key_id:Q.key_id,manifest:W,signature:Q.signature}}function d(z,F){let Q=L(z),Z=F[Q.key_id];if(!Z)throw new J("untrusted_key","Background identity manifest was signed by an unknown key.");let W=A(Q.manifest),w=S(Q.signature),P=!1;try{P=G(null,Buffer.from(q(W)),V(Z),w)}catch{throw new J("invalid_signature","Background identity manifest signature could not be verified.")}if(!P)throw new J("invalid_signature","Background identity manifest signature did not match.");return{key_id:Q.key_id,manifest:W,signature:Q.signature}}function i(z,F){let Q=z;if(typeof z==="string")try{Q=JSON.parse(z)}catch{throw new J("invalid_manifest","Legacy managed runtime manifest is not valid JSON.")}if(!X(Q)||!$(Q,["key_id","manifest","signature"])||typeof Q.key_id!=="string"||!/^[A-Za-z0-9._-]{1,80}$/.test(Q.key_id)||typeof Q.signature!=="string")throw new J("invalid_manifest","Signed legacy managed runtime manifest is invalid.");let Z=F[Q.key_id];if(!Z)throw new J("untrusted_key","Legacy runtime manifest was signed by an unknown key.");let W=M(Q.manifest),w=S(Q.signature),P=!1;try{P=G(null,Buffer.from(q(W)),V(Z),w)}catch{throw new J("invalid_signature","Legacy runtime manifest signature could not be verified.")}if(!P)throw new J("invalid_signature","Legacy runtime manifest signature did not match.");return{key_id:Q.key_id,manifest:W,signature:Q.signature}}function y(z){return f("sha256").update(z).digest("hex")}function n(z,F){if(z.byteLength!==F.size_bytes)throw new J("artifact_size_mismatch","Runtime artifact size did not match its manifest.");if(y(z)!==F.sha256)throw new J("artifact_checksum_mismatch","Runtime artifact checksum did not match its manifest.")}import{existsSync as p}from"fs";import{join as T}from"path";function r(z){let F=T(z,H);return p(F)?F:T(z,Y)}
|
|
3
|
-
export{Y as ei,H as fi,k as gi,x as hi,h as ii,R as ji,U as ki,J as li,K as mi,g as ni,o as oi,q as pi,E as qi,d as ri,i as si,y as ti,n as ui,r as vi};
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
import{Rk as M}from"./vm-hands-entry-lite-40nkzw38.js";import{Xk as G}from"./vm-hands-entry-lite-72nn2b4n.js";import{readdirSync as D,readFileSync as I}from"fs";import{userInfo as A}from"os";var O="--vm-hands-op-runner-kind=person";function x(q){let Q=new Set([q]),K=[];try{K=D("/proc")}catch{}for(let z of K){if(!/^\d+$/.test(z))continue;try{let X=I(`/proc/${z}/stat`,"utf8");if(Number(X.slice(X.lastIndexOf(")")+2).split(" ")[3])===q)Q.add(Number(z))}catch{}}for(let z of Q)try{process.kill(z,"SIGKILL")}catch{}}var C=(q)=>{let Q=globalThis.Bun;if(!Q)throw new M("pty_unavailable","Reason terminals require the Bun runtime.");let K=Q.spawn({cmd:[q.shell,...q.args],cwd:q.cwd,env:{...q.environment,TERM:"xterm-256color"},terminal:{cols:q.cols,rows:q.rows,data:(J,Y)=>q.onData(Y)}}),z=K.terminal,X=()=>{x(K.pid);try{z?.close()}catch{}};if(!z)throw X(),new M("pty_unavailable","Reason could not allocate a pseudo-terminal.");return{write:(J)=>z.write(J),resize:(J,Y)=>z.resize(J,Y),kill:X,exited:K.exited.then((J)=>typeof J==="number"?J:null,()=>null)}};function L(){let q=(()=>{try{return A().username}catch{return}})();return{PATH:process.env.PATH,HOME:process.env.HOME,SHELL:process.env.SHELL,LANG:"C.UTF-8",...q?{USER:q,LOGNAME:q}:{}}}async function P(){let[{executeLocalOperation:q,spawnCaptured:Q},{runLocalPtySession:K},{configureDesktopAccount:z},{configureWorkerSandbox:X}]=await Promise.all([import("./local-capabilities-dgaqqaw9.js"),import("./local-pty-session-fe6jz2zy.js"),import("./desktop-account-2kkxwv1y.js"),import("./worker-sandbox-p242st5d.js")]);X();let T=process.argv.includes(O),J=($,j,F)=>Q($,j[0]==="-lic"?["-lc",...j.slice(1)]:j,F),Y=(process.geteuid?.()??0)!==0,H=new Map,Z=($)=>{try{process.send?.($)}catch{}};process.on("message",($)=>{let j=$;if(j?.t==="cancel"){H.get(j.id)?.abort();return}if(j?.t!=="op")return;if(!Y){Z({t:"done",id:j.id,completion:{status:"failed",error_code:"vm_hands_payload_account_unavailable"}});return}let F=j.claim.capability;if(F==="pty.start"&&!T){Z({t:"done",id:j.id,completion:{status:"failed",error_code:"capability_not_granted"}});return}let U=new AbortController;H.set(j.id,U);let V=F==="pty.start"?{runPtySession:(B)=>K(B,{spawnPty:C,environment:L(),loadProxy:()=>null})}:{worker:j.worker,...F==="exec.full"?{spawnFullControl:J}:{}};q(j.state,j.claim,{...V,signal:U.signal,emit:(B)=>{let{deliverySignal:N,...W}=B;Z({t:"event",id:j.id,event:W})}}).then((B)=>Z({t:"done",id:j.id,completion:B}),(B)=>Z({t:"done",id:j.id,completion:{status:"failed",error_code:B&&typeof B==="object"&&"code"in B&&typeof B.code==="string"?B.code:"vm_hands_op_failed"}})).finally(()=>H.delete(j.id))}),process.on("disconnect",()=>process.exit(0)),await new Promise(()=>{})}
|
|
3
|
-
export{O as s,C as t,P as u};
|