@symerian/symi 3.5.22 → 3.5.24
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/dist/{agent-NT0EKnK_.js → agent-CBfp75J4.js} +18 -18
- package/dist/{agent-scope-Bnsyyeci.js → agent-scope-DOrZjOnW.js} +18 -18
- package/dist/{agents.config-DA0ISLi7.js → agents.config-B7sNDvhz.js} +1 -1
- package/dist/{audit-CXIXYDRx.js → audit-Ce-u6aaR.js} +20 -20
- package/dist/{auth-choice-BtXIQPTU.js → auth-choice-CUvx59kv.js} +11 -11
- package/dist/{auth-profiles-D5nYBj_Z.js → auth-profiles-Ce7R_25e.js} +2 -2
- package/dist/{auth-token-fgnCQEHT.js → auth-token-Cr28IDKY.js} +3 -3
- package/dist/{browser-cli-DOTM7UBC.js → browser-cli-Ibgld3mA.js} +9 -9
- package/dist/build-info.json +3 -3
- package/dist/{call-Bpjj5p7I.js → call-xdEE97oU.js} +9 -9
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/dist/{channel-options-XRJiHUm5.js → channel-options-DCmWOAc0.js} +1 -1
- package/dist/{channels-cli-CQ4M05oy.js → channels-cli-Cs1Z0dn8.js} +57 -57
- package/dist/{chrome-DNssqQJs.js → chrome-3jl2ulOE.js} +7 -7
- package/dist/{chrome-38OnGyuN.js → chrome-DJChpTwP.js} +2 -2
- package/dist/{cli-B-uoiYP2.js → cli-CadU09SC.js} +45 -45
- package/dist/{client-CTrfpKT3.js → client-Cs9Bh-G0.js} +1 -1
- package/dist/{commands-registry-CwXsDVuO.js → commands-registry-Ca5hh7nh.js} +1 -1
- package/dist/{completion-cli-Cn_81QBb.js → completion-cli-Dd56ibFZ.js} +12 -12
- package/dist/{config-BngIfn5l.js → config-B4jkreCN.js} +2 -2
- package/dist/{config-cli-B1cPkJ4p.js → config-cli-GwUJEapt.js} +4 -4
- package/dist/{config-guard-DStz4_V2.js → config-guard-BRm3RiOi.js} +6 -6
- package/dist/{config-validation-Dxj9LRzr.js → config-validation-Cdyg1BZB.js} +1 -1
- package/dist/{configure-C7zmSgvC.js → configure-5md67tCP.js} +14 -14
- package/dist/{consolidate-CO32_TEx.js → consolidate-DymnvvYm.js} +6 -6
- package/dist/{control-service-CUreKVeY.js → control-service-D8kKOts5.js} +4 -4
- package/dist/control-ui/css/style.css +36 -4
- package/dist/{control-ui-assets-B8B9z_Ll.js → control-ui-assets-CJQ97d4u.js} +1 -1
- package/dist/{cost-cli-D-ssjcRF.js → cost-cli-DWiVCOCx.js} +3 -3
- package/dist/{cron-cli-otPeKxmi.js → cron-cli-CE9bV9Et.js} +7 -7
- package/dist/{daemon-cli-qDdMg615.js → daemon-cli-BYiG4GOU.js} +11 -11
- package/dist/{daemon-runtime-CKn0wmCk.js → daemon-runtime-DlQla_dA.js} +10 -10
- package/dist/{deliver-q23ar_Pm.js → deliver-f3cIWxXT.js} +4 -4
- package/dist/{deliver-CWMFmMCv.js → deliver-lTZLIQqf.js} +2 -2
- package/dist/{deps-CdibsPMx.js → deps-Bf9dt2UO.js} +1 -1
- package/dist/{devices-cli-DDPwF2Nx.js → devices-cli-Bhr6jGtH.js} +6 -6
- package/dist/{diagnostics-CYkqD5lP.js → diagnostics-DlZODdRf.js} +5 -5
- package/dist/{directory-cli-giqTe8Yg.js → directory-cli-Bm5QYEo-.js} +3 -3
- package/dist/{dm-policy-shared-B61_yf6G.js → dm-policy-shared-CeFt0nch.js} +1 -1
- package/dist/{dns-cli-Dssz4RqF.js → dns-cli-CubLq4j9.js} +3 -3
- package/dist/{docs-cli-Ct1STieY.js → docs-cli-PS8m1er7.js} +1 -1
- package/dist/{doctor-completion-CL7MyXlo.js → doctor-completion-BpUGRguQ.js} +2 -2
- package/dist/{doctor-config-flow-ljVnQJjo.js → doctor-config-flow-C52W1uUK.js} +9 -9
- package/dist/{exec-approvals-cli-DsBoQu5H.js → exec-approvals-cli-CzvIqBUd.js} +13 -13
- package/dist/extensionAPI.js +4 -4
- package/dist/{file-lock-2AecMjCa.js → file-lock-BVUYnlQv.js} +8 -8
- package/dist/{fs-safe-B0Is-oLk.js → fs-safe-BdejYjW8.js} +6 -6
- package/dist/{gateway-cli-DG_2YZ8B.js → gateway-cli-D1d5YAt0.js} +98 -98
- package/dist/{gateway-rpc-gaoD882s.js → gateway-rpc-BTGT1SuZ.js} +1 -1
- package/dist/{glass-ui-ws-Bof7krDJ.js → glass-ui-ws-BH9WH_VN.js} +67 -67
- package/dist/{health-CMbUI4aN.js → health-DpE9GWGn.js} +4 -4
- package/dist/{hooks-cli-Cgjor7F-.js → hooks-cli-D7xxbEwI.js} +59 -59
- package/dist/{image-ops-BzCBIakN.js → image-ops-L70xVnpG.js} +10 -10
- package/dist/index.js +52 -52
- package/dist/{inspect-DzYUb_Dl.js → inspect-CGKsaVZ4.js} +4 -4
- package/dist/{install-safe-path-BrpA09f2.js → install-safe-path-B2JrFspY.js} +11 -11
- package/dist/{installs-bnDlOSq2.js → installs-D890uIIW.js} +10 -10
- package/dist/{internal-csqU78gW.js → internal-DVCddhhN.js} +9 -9
- package/dist/{lifecycle-core-cSR_xiIO.js → lifecycle-core-wFwnK_mD.js} +5 -5
- package/dist/{local-roots-2Jb79HZ8.js → local-roots-CgDCgCuM.js} +1 -1
- package/dist/{logs-cli-Kr145PO_.js → logs-cli-DvIVuW0d.js} +7 -7
- package/dist/{manager-DG6PODgu.js → manager-CoCX7L5u.js} +15 -15
- package/dist/{manager-qrAOWmHt.js → manager-V4UCf0Av.js} +1 -1
- package/dist/{memory-BFnx3v3_.js → memory-B067LTL9.js} +5 -5
- package/dist/{memory-cli-CHNghdrm.js → memory-cli-D8Z_5-Nz.js} +12 -12
- package/dist/{model-Cwbcw-km.js → model-MUMSB_7d.js} +1 -1
- package/dist/{model-auth-_C07_3Yr.js → model-auth-1EAQvYRv.js} +2 -2
- package/dist/{model-catalog-BWurV7gl.js → model-catalog-IWi6-nY9.js} +3 -3
- package/dist/{model-picker-Dpkr5xBW.js → model-picker-Cf6UgQEh.js} +5 -5
- package/dist/{model-selection-CCTzD29o.js → model-selection-7wdmO-Iw.js} +1 -1
- package/dist/{models-cli-BbK8HMKa.js → models-cli-C979SN3Z.js} +55 -55
- package/dist/{models-config-DlXge3Sd.js → models-config-B5Xxy-c-.js} +8 -8
- package/dist/{node-cli-BPnBosC4.js → node-cli-DGybtex_.js} +27 -27
- package/dist/{node-service-Cc18m-uk.js → node-service-BH08wY5j.js} +1 -1
- package/dist/{nodes-cli-CN_m6PO5.js → nodes-cli-C-mEw2av.js} +10 -10
- package/dist/{nodes-screen-Cp5QP3ET.js → nodes-screen-De9ma6e1.js} +4 -4
- package/dist/{npm-registry-spec-C-muP97-.js → npm-registry-spec-DTqn-NXZ.js} +9 -9
- package/dist/{onboard-B2IcTMv-.js → onboard-CotuAZi6.js} +15 -15
- package/dist/{onboard-channels-wfGO5Zlh.js → onboard-channels-DSyynpou.js} +4 -4
- package/dist/{onboard-custom-DnDrvxSg.js → onboard-custom-BcRYreNG.js} +3 -3
- package/dist/{onboard-helpers-BKejzolA.js → onboard-helpers-CLXJ8zp0.js} +8 -8
- package/dist/{onboard-hooks-D9jHwImb.js → onboard-hooks-2SCajRKc.js} +1 -1
- package/dist/{onboard-remote-y3ZmP90U.js → onboard-remote-BYBai0w3.js} +1 -1
- package/dist/{onboard-skills-BFhHfrt9.js → onboard-skills-BxJlS1Bk.js} +3 -3
- package/dist/{onboarding-DqlPV372.js → onboarding-BnoGiOh3.js} +12 -12
- package/dist/{onboarding.finalize-Bwjv3jew.js → onboarding.finalize-g86Q4433.js} +31 -31
- package/dist/{onboarding.gateway-config-CiRo9EMt.js → onboarding.gateway-config-CEXjbEM0.js} +8 -8
- package/dist/{openai-model-default-De-UAjwg.js → openai-model-default-BkuuK-Di.js} +2 -2
- package/dist/{pairing-cli-CBMMCNnx.js → pairing-cli-Rsae0KnN.js} +5 -5
- package/dist/{pairing-store-Be-ZQK87.js → pairing-store-BNhJOnWn.js} +1 -1
- package/dist/{pairing-token-B703A1U3.js → pairing-token-Dcy37-4s.js} +7 -7
- package/dist/{paths-BWqg8NZT.js → paths-DObzwe08.js} +1 -1
- package/dist/{pi-auth-json-D-vdh-nY.js → pi-auth-json-Db8XJVGL.js} +6 -6
- package/dist/{pi-embedded-CviuByGd.js → pi-embedded-B9rtlNMc.js} +10 -10
- package/dist/{pi-embedded-helpers-j1JrlsI0.js → pi-embedded-helpers-D-OFjhdI.js} +6 -6
- package/dist/{pi-tools.policy-CvAqjEH9.js → pi-tools.policy-H2t-Xkfc.js} +3 -3
- package/dist/{plugin-auto-enable-BXSJTxI7.js → plugin-auto-enable-DJBhDIMq.js} +1 -1
- package/dist/{plugin-registry-B43UosQh.js → plugin-registry-AsC9gydF.js} +3 -3
- package/dist/plugin-sdk/index.js +6 -6
- package/dist/{plugins-cli-BV2wbjfI.js → plugins-cli-CbByGz8z.js} +54 -54
- package/dist/{ports-CB_Iu83U.js → ports-gxLM5ahL.js} +2 -2
- package/dist/{ports-Bi3V_3n9.js → ports-r7LBic2V.js} +1 -1
- package/dist/{program-context-BmXxHUKe.js → program-context-CiyK6MfV.js} +40 -40
- package/dist/{prompt-select-styled-BlQZX6pK.js → prompt-select-styled-DaNQ_GgB.js} +38 -38
- package/dist/{provider-auth-helpers-WLwb6tL4.js → provider-auth-helpers-D2FDvwT5.js} +6 -6
- package/dist/{push-apns-CBGvXev_.js → push-apns-va-DRu4U.js} +4 -4
- package/dist/{pw-ai-CP5pn3eU.js → pw-ai-BiBvIJzd.js} +7 -7
- package/dist/{pw-ai-v__CyAlM.js → pw-ai-DOAsQ5NX.js} +1 -1
- package/dist/{qmd-manager-Dxyue7B1.js → qmd-manager-C8-M4Pru.js} +19 -19
- package/dist/{qr-cli-DHw6muwK.js → qr-cli-1sCVaPcF.js} +3 -3
- package/dist/{register.agent-CXdTiqyP.js → register.agent-BqdQ0s30.js} +67 -67
- package/dist/{register.configure-DVcn-gCO.js → register.configure-Dhwi-4FG.js} +70 -70
- package/dist/{register.maintenance-cpspl8D6.js → register.maintenance-iMjNw9uy.js} +67 -67
- package/dist/{register.message-BjcYy5UG.js → register.message-Ao_b9s2g.js} +47 -47
- package/dist/{register.onboard-D4RN92s2.js → register.onboard-ymhSAezZ.js} +25 -25
- package/dist/{register.setup-BvoXF0xl.js → register.setup-CKs9mqtD.js} +28 -28
- package/dist/{register.status-health-sessions-DjDvCXBn.js → register.status-health-sessions-U-azRmpb.js} +41 -41
- package/dist/{replies-B_3j7R_Q.js → replies-CbXXjn9X.js} +1 -1
- package/dist/{reply-prefix-CtZtkTJK.js → reply-prefix-BFNeXT65.js} +1 -1
- package/dist/{resolve-route-Du0VftVs.js → resolve-route-C1IIA6kH.js} +1 -1
- package/dist/{routes-BwTUoI5h.js → routes-ivqbutvM.js} +10 -10
- package/dist/{rpc-CwxSZZOx.js → rpc-DjqFrbOc.js} +1 -1
- package/dist/{sandbox-CZGTCone.js → sandbox-BkznAPKO.js} +18 -18
- package/dist/{sandbox-cli-DEtGT_4y.js → sandbox-cli-Bb9cBtBH.js} +13 -13
- package/dist/{security-cli-DJd7Fcdy.js → security-cli-JKsf9SIu.js} +29 -29
- package/dist/{send-CxjvucMO.js → send-B0jHSNMF.js} +7 -7
- package/dist/{server-context-DXdk410X.js → server-context-ChcbJgNo.js} +5 -5
- package/dist/{server-methods-DfVfzYqq.js → server-methods-B2tykucj.js} +60 -60
- package/dist/{server-node-events-B0yC6hi1.js → server-node-events-BKqszk_a.js} +48 -48
- package/dist/{service-CRZoXO_n.js → service-e6MzlLCd.js} +15 -15
- package/dist/{session-dirs-a00Ad2SO.js → session-dirs-C9E2G0yZ.js} +2 -2
- package/dist/{session-utils-CJhcRx3E.js → session-utils-Cs1jlD-q.js} +14 -14
- package/dist/{sessions-BCc3THTm.js → sessions-Dxf5Kjig.js} +10 -10
- package/dist/{shared-C39SiDDJ.js → shared-1xPo9ygd.js} +1 -1
- package/dist/{shared-Dh-O8nRd.js → shared-COtpr3Ad.js} +3 -3
- package/dist/{skill-commands-DWvXs3lz.js → skill-commands-DDGGlq68.js} +4 -4
- package/dist/{skill-scanner-CIlHPszT.js → skill-scanner-BCgVcIwi.js} +5 -5
- package/dist/{skills-CYcBtLGH.js → skills-BwDmcZdt.js} +4 -4
- package/dist/{skills-cli-CD9s3cgm.js → skills-cli-B-7TY-vS.js} +7 -7
- package/dist/{skills-install-BTa9IuQ6.js → skills-install-Dwzsjoc8.js} +3 -3
- package/dist/{skills-remote-BcRQTDsZ.js → skills-remote-bz71Bstn.js} +3 -3
- package/dist/{skills-status-DLnCHUZ2.js → skills-status-BKX1PjCc.js} +1 -1
- package/dist/{sqlite-BpogPlQW.js → sqlite-Cod7C5ba.js} +5 -5
- package/dist/{status-BWxLtb3D.js → status-DHBVIMyL.js} +23 -23
- package/dist/{status-Doq8T1zj.js → status-DPGFZPpp.js} +3 -3
- package/dist/{status.update-CKfyV6zw.js → status.update-DGJi0OLl.js} +3 -3
- package/dist/{symframe-cli-D1CtN3pf.js → symframe-cli-CX3dINPw.js} +9 -9
- package/dist/{symi-root-DeCVdZB4.js → symi-root-BQ0IpoW2.js} +2 -2
- package/dist/{synthesis-DuP2d469.js → synthesis-Bc2QkGvt.js} +4 -4
- package/dist/{synthesis-VZNnlUTf.js → synthesis-DmqicCsT.js} +45 -45
- package/dist/{system-cli-r7WJj0Xh.js → system-cli-DUHzCGfK.js} +7 -7
- package/dist/{systemd-CsoVnIbM.js → systemd-CUIM0n5P.js} +5 -5
- package/dist/{systemd-hints-QISwLlFU.js → systemd-hints-CsrzMCTD.js} +6 -6
- package/dist/{systemd-linger-BnhuRdbt.js → systemd-linger-BzYk7A6M.js} +1 -1
- package/dist/{tui-J7Jxp-FF.js → tui-DCqVZ6sC.js} +7 -7
- package/dist/{tui-cli-DR48dU_C.js → tui-cli-CI-P3sei.js} +19 -19
- package/dist/{unified-runner-DXjH-prv.js → unified-runner-CznU7Ad0.js} +101 -101
- package/dist/{update-check-u6Jgr1cz.js → update-check-BCL_K7kx.js} +5 -5
- package/dist/{update-cli-CKpjWtlv.js → update-cli-DBoIBDNe.js} +77 -77
- package/dist/{update-runner-G2YgEATs.js → update-runner-BLV8SI96.js} +15 -15
- package/dist/{update-Cb0Fmxic.js → update-yYduAjKd.js} +3 -3
- package/dist/{webhooks-cli-DjUITimx.js → webhooks-cli-D5k-Y2A8.js} +4 -4
- package/dist/{with-timeout-CLrF-Yr_.js → with-timeout-DPR4A2dx.js} +1 -1
- package/dist/{workspace-dirs-DCICLTHx.js → workspace-dirs-jKFQf7of.js} +1 -1
- package/dist/{wsl-DTi7eX-V.js → wsl-CglTdtlb.js} +2 -2
- package/extensions/memory-core/package.json +1 -1
- package/extensions/msteams/CHANGELOG.md +12 -0
- package/extensions/msteams/package.json +1 -1
- package/extensions/open-prose/package.json +1 -1
- package/extensions/outlook/package.json +1 -1
- package/extensions/slack/package.json +1 -1
- package/package.json +1 -1
|
@@ -1,60 +1,60 @@
|
|
|
1
|
-
import { D as ensureOutboundSessionEntry, Ft as normalizeGroupActivation, I as normalizeCronJobCreate, Kt as resolveAgentTimeoutMs, L as normalizeCronJobPatch, Lt as formatZonedTimestamp, Nt as prepareAgentRun, O as resolveOutboundSessionRoute, Pt as BARE_SESSION_RESET_PROMPT, Rt as isAbortTrigger, St as parseVerboseOverride, Ut as listDescendantRunsForRequester, Wt as listSubagentRunsForRequester, Zt as clearSessionQueues, b as prepareReplyTurn, bt as applyModelOverrideToSessionEntry, et as applyBrowserProxyPaths, f as getChannelActivity, g as buildGlassUiProfile, ht as resolveSendPolicy, in as abortEmbeddedPiRun, j as normalizePollInput, k as resolveOutboundTarget, m as createReplyDispatcher, mt as normalizeSendPolicy, nn as registerAgentRunContext, on as waitForEmbeddedPiRunEnd, pn as resolveUserTimezone, s as loadSymiPlugins, st as scheduleGatewaySigusr1Restart, tn as onAgentEvent, tt as persistBrowserProxyFiles, v as runUnifiedTurn, w as listTasksInWorkdir, xt as applyVerboseOverride, y as buildAgentTurnParams, zt as stopSubagentsForRequester } from "./unified-runner-
|
|
1
|
+
import { D as ensureOutboundSessionEntry, Ft as normalizeGroupActivation, I as normalizeCronJobCreate, Kt as resolveAgentTimeoutMs, L as normalizeCronJobPatch, Lt as formatZonedTimestamp, Nt as prepareAgentRun, O as resolveOutboundSessionRoute, Pt as BARE_SESSION_RESET_PROMPT, Rt as isAbortTrigger, St as parseVerboseOverride, Ut as listDescendantRunsForRequester, Wt as listSubagentRunsForRequester, Zt as clearSessionQueues, b as prepareReplyTurn, bt as applyModelOverrideToSessionEntry, et as applyBrowserProxyPaths, f as getChannelActivity, g as buildGlassUiProfile, ht as resolveSendPolicy, in as abortEmbeddedPiRun, j as normalizePollInput, k as resolveOutboundTarget, m as createReplyDispatcher, mt as normalizeSendPolicy, nn as registerAgentRunContext, on as waitForEmbeddedPiRunEnd, pn as resolveUserTimezone, s as loadSymiPlugins, st as scheduleGatewaySigusr1Restart, tn as onAgentEvent, tt as persistBrowserProxyFiles, v as runUnifiedTurn, w as listTasksInWorkdir, xt as applyVerboseOverride, y as buildAgentTurnParams, zt as stopSubagentsForRequester } from "./unified-runner-CznU7Ad0.js";
|
|
2
2
|
import { H as createInternalHookEvent, P as getResolvedLoggerSettings, W as triggerInternalHook, d as getActivePluginRegistry, r as DEFAULT_CHAT_CHANNEL } from "./registry-Sbac4a4z.js";
|
|
3
3
|
import { _ as resolveStateDir, t as CONFIG_PATH } from "./paths-By0XjHBk.js";
|
|
4
4
|
import { S as isPlainObject, h as resolveUserPath, n as clamp } from "./utils-CTPsqyE_.js";
|
|
5
5
|
import { f as defaultRuntime, t as createSubsystemLogger } from "./subsystem-CHbO_DkH.js";
|
|
6
6
|
import { a as classifySessionKeyShape, b as isSubagentSessionKey, c as resolveAgentIdFromSessionKey, o as normalizeAgentId, p as DEFAULT_ACCOUNT_ID, t as DEFAULT_AGENT_ID, x as parseAgentSessionKey } from "./session-key-DUSb7CCb.js";
|
|
7
|
-
import { t as resolveSymiPackageRoot } from "./symi-root-
|
|
8
|
-
import { C as ensureAgentWorkspace, S as DEFAULT_USER_FILENAME, T as isWorkspaceOnboardingCompleted, _ as DEFAULT_MEMORY_ALT_FILENAME, b as DEFAULT_SYMIPULSE_FILENAME, c as resolveAgentWorkspaceDir, d as resolveSessionAgentId, g as DEFAULT_IDENTITY_FILENAME, h as DEFAULT_BOOTSTRAP_FILENAME, i as resolveAgentDir, l as resolveDefaultAgentId, n as listAgentIds, p as DEFAULT_AGENTS_FILENAME, t as listAgentEntries, v as DEFAULT_MEMORY_FILENAME, x as DEFAULT_TOOLS_FILENAME, y as DEFAULT_SYMICORE_FILENAME } from "./agent-scope-
|
|
9
|
-
import { b as resolveThinkingDefault, f as resolveAllowedModelRef, h as resolveDefaultModelForAgent, v as resolveSubagentConfiguredModelSelection } from "./model-selection-
|
|
7
|
+
import { t as resolveSymiPackageRoot } from "./symi-root-BQ0IpoW2.js";
|
|
8
|
+
import { C as ensureAgentWorkspace, S as DEFAULT_USER_FILENAME, T as isWorkspaceOnboardingCompleted, _ as DEFAULT_MEMORY_ALT_FILENAME, b as DEFAULT_SYMIPULSE_FILENAME, c as resolveAgentWorkspaceDir, d as resolveSessionAgentId, g as DEFAULT_IDENTITY_FILENAME, h as DEFAULT_BOOTSTRAP_FILENAME, i as resolveAgentDir, l as resolveDefaultAgentId, n as listAgentIds, p as DEFAULT_AGENTS_FILENAME, t as listAgentEntries, v as DEFAULT_MEMORY_FILENAME, x as DEFAULT_TOOLS_FILENAME, y as DEFAULT_SYMICORE_FILENAME } from "./agent-scope-DOrZjOnW.js";
|
|
9
|
+
import { b as resolveThinkingDefault, f as resolveAllowedModelRef, h as resolveDefaultModelForAgent, v as resolveSubagentConfiguredModelSelection } from "./model-selection-7wdmO-Iw.js";
|
|
10
10
|
import { n as normalizeSecretInput } from "./normalize-secret-input-DjGU5EXe.js";
|
|
11
|
-
import { N as VERSION, P as resolveRuntimeServiceVersion, T as applyLegacyMigrations, a as parseConfigJson5, c as resolveConfigSnapshotHash, d as SymiSchema, i as loadConfig, l as writeConfigFile, m as sensitive, o as readConfigFileSnapshot, s as readConfigFileSnapshotForWrite, u as validateConfigObjectWithPlugins, w as applyMergePatch } from "./config-
|
|
11
|
+
import { N as VERSION, P as resolveRuntimeServiceVersion, T as applyLegacyMigrations, a as parseConfigJson5, c as resolveConfigSnapshotHash, d as SymiSchema, i as loadConfig, l as writeConfigFile, m as sensitive, o as readConfigFileSnapshot, s as readConfigFileSnapshotForWrite, u as validateConfigObjectWithPlugins, w as applyMergePatch } from "./config-B4jkreCN.js";
|
|
12
12
|
import { c as pickPrimaryLanIPv4 } from "./ws-C7Ktmt-R.js";
|
|
13
|
-
import { i as loadWorkspaceSkillEntries } from "./skills-
|
|
13
|
+
import { i as loadWorkspaceSkillEntries } from "./skills-BwDmcZdt.js";
|
|
14
14
|
import { t as movePathToTrash } from "./trash-_YhavPQI.js";
|
|
15
|
-
import { B as resolveAgentMainSessionKey, C as capArrayByJsonBytes, D as resolveSessionTranscriptCandidates, G as snapshotSessionOrigin, H as resolveMainSessionKey, O as stripEnvelopeFromMessages, S as archiveSessionTranscripts, T as readSessionPreviewItemsFromTranscript, U as resolveMainSessionKeyFromConfig, V as resolveExplicitAgentSessionKey, d as updateSessionStore, o as loadSessionStore, t as extractDeliveryInfo, w as readSessionMessages, x as archiveFileOnDisk, y as normalizeSessionDeliveryFields } from "./sessions-
|
|
15
|
+
import { B as resolveAgentMainSessionKey, C as capArrayByJsonBytes, D as resolveSessionTranscriptCandidates, G as snapshotSessionOrigin, H as resolveMainSessionKey, O as stripEnvelopeFromMessages, S as archiveSessionTranscripts, T as readSessionPreviewItemsFromTranscript, U as resolveMainSessionKeyFromConfig, V as resolveExplicitAgentSessionKey, d as updateSessionStore, o as loadSessionStore, t as extractDeliveryInfo, w as readSessionMessages, x as archiveFileOnDisk, y as normalizeSessionDeliveryFields } from "./sessions-Dxf5Kjig.js";
|
|
16
16
|
import { f as GATEWAY_CLIENT_CAPS, g as hasGatewayClientCap, i as isGatewayMessageChannel, l as normalizeMessageChannel, n as isDeliverableMessageChannel, t as INTERNAL_MESSAGE_CHANNEL } from "./message-channel-DgjXWzf-.js";
|
|
17
17
|
import { n as listChannelPlugins, r as normalizeChannelId, t as getChannelPlugin } from "./plugins-CF5skkHh.js";
|
|
18
18
|
import { c as resolveStorePath, n as resolveSessionFilePath, r as resolveSessionFilePathOptions, s as resolveSessionTranscriptsDirForAgent } from "./paths-BtvQ7JvU.js";
|
|
19
19
|
import { i as normalizeInputProvenance } from "./input-provenance-Dfn-vEsu.js";
|
|
20
20
|
import { a as normalizeElevatedLevel, c as normalizeUsageDisplay, d as supportsXHighThinking, n as formatXHighModelHint, o as normalizeReasoningLevel, s as normalizeThinkLevel, t as formatThinkingLevels } from "./thinking-COroyVA5.js";
|
|
21
|
-
import { h as getGlobalHookRunner, o as normalizeReplyPayloadsForDelivery, t as deliverOutboundPayloads } from "./deliver-
|
|
21
|
+
import { h as getGlobalHookRunner, o as normalizeReplyPayloadsForDelivery, t as deliverOutboundPayloads } from "./deliver-lTZLIQqf.js";
|
|
22
22
|
import { i as loadSessionUsageTimeSeries, n as loadCostUsageSummary, r as loadSessionCostSummary, t as discoverAllSessions } from "./session-cost-usage-D3mgssM_.js";
|
|
23
|
-
import { C as enqueueSystemEvent, _ as loadProviderUsageSummary, a as loadCombinedSessionStoreForGateway, c as resolveGatewaySessionStoreTarget, d as formatDoctorNonInteractiveHint, g as writeRestartSentinel, i as listSessionsFromStore, l as resolveSessionModelRef, o as loadSessionEntry, r as listAgentsForGateway, s as pruneLegacyStoreKeys, t as canonicalizeSpawnedByForAgent, w as isSystemEventContextChanged } from "./session-utils-
|
|
24
|
-
import { n as createBrowserRouteDispatcher } from "./with-timeout-
|
|
25
|
-
import { a as resolveAgentIdentity, t as createReplyPrefixOptions } from "./reply-prefix-
|
|
26
|
-
import { t as getMemorySearchManager } from "./memory-
|
|
27
|
-
import { $ as validateNodeInvokeResultParams, $t as rotateDeviceToken, A as validateCronListParams, At as validateTasksListParams, B as validateDeviceTokenRevokeParams, Bt as ErrorCodes, C as validateConfigApplyParams, Ct as validateSessionsUsageParams, D as validateConfigSetParams, Dt as validateSkillsUpdateParams, E as validateConfigSchemaParams, Et as validateSkillsStatusParams, F as validateCronUpdateParams, Ft as validateWizardCancelParams, G as validateExecApprovalsNodeGetParams, Gt as approveDevicePairing, I as validateDevicePairApproveParams, It as validateWizardNextParams, J as validateLogsTailParams, Jt as listDevicePairing, K as validateExecApprovalsNodeSetParams, L as validateDevicePairListParams, Lt as validateWizardStartParams, M as validateCronRunParams, Mt as validateWakeParams, N as validateCronRunsParams, Nt as validateWebLoginStartParams, Ot as validateTalkConfigParams, P as validateCronStatusParams, Pt as validateWebLoginWaitParams, Q as validateNodeInvokeParams, Qt as revokeDeviceToken, R as validateDevicePairRejectParams, Rt as validateWizardStatusParams, S as validateChatToolsListParams, St as validateSessionsSearchParams, T as validateConfigPatchParams, Tt as validateSkillsInstallParams, Ut as parseSessionLabel, V as validateDeviceTokenRotateParams, Vt as errorShape, W as validateExecApprovalsGetParams, X as validateNodeDescribeParams, Xt as removePairedDevice, Y as validateModelsListParams, Yt as rejectDevicePairing, Z as validateNodeEventParams, _ as validateChatHistoryParams, _t as validateSessionsPatchParams, a as validateAgentWaitParams, at as validateNodePairVerifyParams, b as validateChatSkillsListParams, bt as validateSessionsResolveParams, c as validateAgentsFilesGetParams, ct as validatePushTestParams, d as validateAgentsListParams, dt as validateSessionsAdoptFileParams, en as summarizeDeviceTokens, et as validateNodeListParams, f as validateAgentsUpdateParams, ft as validateSessionsCompactParams, g as validateChatCommandsListParams, gt as validateSessionsListParams, h as validateChatAbortParams, ht as validateSessionsFavoriteFileParams, i as validateAgentParams, it as validateNodePairRequestParams, j as validateCronRemoveParams, jt as validateUpdateRunParams, k as validateCronAddParams, kt as validateTalkModeParams, l as validateAgentsFilesListParams, m as validateChannelsStatusParams, mt as validateSessionsDeleteParams, n as formatValidationErrors, nt as validateNodePairListParams, o as validateAgentsCreateParams, ot as validateNodeRenameParams, p as validateChannelsLogoutParams, pt as validateSessionsDeleteFileParams, q as validateExecApprovalsSetParams, r as validateAgentIdentityParams, rt as validateNodePairRejectParams, s as validateAgentsDeleteParams, st as validatePollParams, tt as validateNodePairApproveParams, u as validateAgentsFilesSetParams, ut as validateSendParams, v as validateChatInjectParams, vt as validateSessionsPreviewParams, w as validateConfigGetParams, wt as validateSkillsBinsParams, x as validateChatSymframePushParams, xt as validateSessionsRestoreParams, y as validateChatSendParams, yt as validateSessionsResetParams, z as validateDevicePairRemoveParams } from "./client-
|
|
28
|
-
import { l as authorizeOperatorScopesForMethod, s as ADMIN_SCOPE$2, u as isNodeRoleMethod } from "./call-
|
|
29
|
-
import { c as writeJsonAtomic, o as createAsyncLock, s as readJsonFile } from "./pairing-token-
|
|
30
|
-
import { c as approveNodePairing, d as renamePairedNode, f as requestNodePairing, l as listNodePairing, m as verifyNodeToken, t as getRemoteSkillEligibility, u as rejectNodePairing } from "./skills-remote-
|
|
31
|
-
import { t as listAgentWorkspaceDirs } from "./workspace-dirs-
|
|
23
|
+
import { C as enqueueSystemEvent, _ as loadProviderUsageSummary, a as loadCombinedSessionStoreForGateway, c as resolveGatewaySessionStoreTarget, d as formatDoctorNonInteractiveHint, g as writeRestartSentinel, i as listSessionsFromStore, l as resolveSessionModelRef, o as loadSessionEntry, r as listAgentsForGateway, s as pruneLegacyStoreKeys, t as canonicalizeSpawnedByForAgent, w as isSystemEventContextChanged } from "./session-utils-Cs1jlD-q.js";
|
|
24
|
+
import { n as createBrowserRouteDispatcher } from "./with-timeout-DPR4A2dx.js";
|
|
25
|
+
import { a as resolveAgentIdentity, t as createReplyPrefixOptions } from "./reply-prefix-BFNeXT65.js";
|
|
26
|
+
import { t as getMemorySearchManager } from "./memory-B067LTL9.js";
|
|
27
|
+
import { $ as validateNodeInvokeResultParams, $t as rotateDeviceToken, A as validateCronListParams, At as validateTasksListParams, B as validateDeviceTokenRevokeParams, Bt as ErrorCodes, C as validateConfigApplyParams, Ct as validateSessionsUsageParams, D as validateConfigSetParams, Dt as validateSkillsUpdateParams, E as validateConfigSchemaParams, Et as validateSkillsStatusParams, F as validateCronUpdateParams, Ft as validateWizardCancelParams, G as validateExecApprovalsNodeGetParams, Gt as approveDevicePairing, I as validateDevicePairApproveParams, It as validateWizardNextParams, J as validateLogsTailParams, Jt as listDevicePairing, K as validateExecApprovalsNodeSetParams, L as validateDevicePairListParams, Lt as validateWizardStartParams, M as validateCronRunParams, Mt as validateWakeParams, N as validateCronRunsParams, Nt as validateWebLoginStartParams, Ot as validateTalkConfigParams, P as validateCronStatusParams, Pt as validateWebLoginWaitParams, Q as validateNodeInvokeParams, Qt as revokeDeviceToken, R as validateDevicePairRejectParams, Rt as validateWizardStatusParams, S as validateChatToolsListParams, St as validateSessionsSearchParams, T as validateConfigPatchParams, Tt as validateSkillsInstallParams, Ut as parseSessionLabel, V as validateDeviceTokenRotateParams, Vt as errorShape, W as validateExecApprovalsGetParams, X as validateNodeDescribeParams, Xt as removePairedDevice, Y as validateModelsListParams, Yt as rejectDevicePairing, Z as validateNodeEventParams, _ as validateChatHistoryParams, _t as validateSessionsPatchParams, a as validateAgentWaitParams, at as validateNodePairVerifyParams, b as validateChatSkillsListParams, bt as validateSessionsResolveParams, c as validateAgentsFilesGetParams, ct as validatePushTestParams, d as validateAgentsListParams, dt as validateSessionsAdoptFileParams, en as summarizeDeviceTokens, et as validateNodeListParams, f as validateAgentsUpdateParams, ft as validateSessionsCompactParams, g as validateChatCommandsListParams, gt as validateSessionsListParams, h as validateChatAbortParams, ht as validateSessionsFavoriteFileParams, i as validateAgentParams, it as validateNodePairRequestParams, j as validateCronRemoveParams, jt as validateUpdateRunParams, k as validateCronAddParams, kt as validateTalkModeParams, l as validateAgentsFilesListParams, m as validateChannelsStatusParams, mt as validateSessionsDeleteParams, n as formatValidationErrors, nt as validateNodePairListParams, o as validateAgentsCreateParams, ot as validateNodeRenameParams, p as validateChannelsLogoutParams, pt as validateSessionsDeleteFileParams, q as validateExecApprovalsSetParams, r as validateAgentIdentityParams, rt as validateNodePairRejectParams, s as validateAgentsDeleteParams, st as validatePollParams, tt as validateNodePairApproveParams, u as validateAgentsFilesSetParams, ut as validateSendParams, v as validateChatInjectParams, vt as validateSessionsPreviewParams, w as validateConfigGetParams, wt as validateSkillsBinsParams, x as validateChatSymframePushParams, xt as validateSessionsRestoreParams, y as validateChatSendParams, yt as validateSessionsResetParams, z as validateDevicePairRemoveParams } from "./client-Cs9Bh-G0.js";
|
|
28
|
+
import { l as authorizeOperatorScopesForMethod, s as ADMIN_SCOPE$2, u as isNodeRoleMethod } from "./call-xdEE97oU.js";
|
|
29
|
+
import { c as writeJsonAtomic, o as createAsyncLock, s as readJsonFile } from "./pairing-token-Dcy37-4s.js";
|
|
30
|
+
import { c as approveNodePairing, d as renamePairedNode, f as requestNodePairing, l as listNodePairing, m as verifyNodeToken, t as getRemoteSkillEligibility, u as rejectNodePairing } from "./skills-remote-bz71Bstn.js";
|
|
31
|
+
import { t as listAgentWorkspaceDirs } from "./workspace-dirs-jKFQf7of.js";
|
|
32
32
|
import { a as mergeExecApprovalsSocketDefaults, c as readExecApprovalsSnapshot, p as saveExecApprovals, r as ensureExecApprovals, s as normalizeExecApprovals } from "./exec-approvals-DioSaIeH.js";
|
|
33
|
-
import { n as createBrowserControlContext, r as startBrowserControlServiceFromConfig } from "./control-service-
|
|
33
|
+
import { n as createBrowserControlContext, r as startBrowserControlServiceFromConfig } from "./control-service-D8kKOts5.js";
|
|
34
34
|
import { i as parseAbsoluteTimeMs } from "./stagger-DQs772BN.js";
|
|
35
|
-
import { n as createOutboundSendDeps } from "./deps-
|
|
35
|
+
import { n as createOutboundSendDeps } from "./deps-Bf9dt2UO.js";
|
|
36
36
|
import { t as buildChannelUiCatalog } from "./catalog-BptA-dUv.js";
|
|
37
|
-
import { t as buildWorkspaceSkillStatus } from "./skills-status-
|
|
37
|
+
import { t as buildWorkspaceSkillStatus } from "./skills-status-BKX1PjCc.js";
|
|
38
38
|
import { t as WizardCancelledError } from "./prompts-CNzp9M83.js";
|
|
39
39
|
import { t as resolveChannelDefaultAccountId } from "./helpers-G6zuddmF.js";
|
|
40
40
|
import { t as buildChannelAccountSnapshot } from "./status-Bah7VY4i.js";
|
|
41
|
-
import { w as resolveAssistantAvatarUrl } from "./onboard-helpers-
|
|
42
|
-
import { c as resolveNodeCommandAllowlist, s as isNodeCommandAllowed } from "./audit-
|
|
43
|
-
import { n as getStatusSummary } from "./status-
|
|
44
|
-
import { m as normalizeUpdateChannel } from "./update-check-
|
|
45
|
-
import { a as sendApnsAlert, c as parseMessageWithAttachments, i as resolveApnsAuthConfigFromEnv, l as formatForLog, n as normalizeApnsEnvironment, o as sendApnsBackgroundWake, s as normalizeRpcAttachmentsToChatAttachments, t as loadApnsRegistration } from "./push-apns-
|
|
46
|
-
import { i as resolveAgentOutboundTarget, r as resolveAgentDeliveryPlan, t as agentCommand } from "./agent-
|
|
47
|
-
import { a as pruneAgentConfig, i as loadAgentIdentity, r as findAgentEntryIndex, t as applyAgentConfig } from "./agents.config-
|
|
41
|
+
import { w as resolveAssistantAvatarUrl } from "./onboard-helpers-CLXJ8zp0.js";
|
|
42
|
+
import { c as resolveNodeCommandAllowlist, s as isNodeCommandAllowed } from "./audit-Ce-u6aaR.js";
|
|
43
|
+
import { n as getStatusSummary } from "./status-DHBVIMyL.js";
|
|
44
|
+
import { m as normalizeUpdateChannel } from "./update-check-BCL_K7kx.js";
|
|
45
|
+
import { a as sendApnsAlert, c as parseMessageWithAttachments, i as resolveApnsAuthConfigFromEnv, l as formatForLog, n as normalizeApnsEnvironment, o as sendApnsBackgroundWake, s as normalizeRpcAttachmentsToChatAttachments, t as loadApnsRegistration } from "./push-apns-va-DRu4U.js";
|
|
46
|
+
import { i as resolveAgentOutboundTarget, r as resolveAgentDeliveryPlan, t as agentCommand } from "./agent-CBfp75J4.js";
|
|
47
|
+
import { a as pruneAgentConfig, i as loadAgentIdentity, r as findAgentEntryIndex, t as applyAgentConfig } from "./agents.config-B7sNDvhz.js";
|
|
48
48
|
import { t as resolveSystemRunCommand } from "./system-run-command-olPQqEUJ.js";
|
|
49
|
-
import { t as installSkill } from "./skills-install-
|
|
50
|
-
import { t as runGatewayUpdate } from "./update-runner-
|
|
49
|
+
import { t as installSkill } from "./skills-install-Dwzsjoc8.js";
|
|
50
|
+
import { t as runGatewayUpdate } from "./update-runner-BLV8SI96.js";
|
|
51
51
|
import crypto, { randomUUID } from "node:crypto";
|
|
52
52
|
import path from "node:path";
|
|
53
|
-
import * as fs$
|
|
53
|
+
import * as fs$2 from "node:fs";
|
|
54
54
|
import fs from "node:fs";
|
|
55
55
|
import * as os$1 from "node:os";
|
|
56
56
|
import os from "node:os";
|
|
57
|
-
import
|
|
57
|
+
import fs$1 from "node:fs/promises";
|
|
58
58
|
import { spawnSync } from "node:child_process";
|
|
59
59
|
import { z } from "zod";
|
|
60
60
|
import { CURRENT_SESSION_VERSION, SessionManager } from "@mariozechner/pi-coding-agent";
|
|
@@ -401,20 +401,20 @@ function resolveCronRunLogPath(params) {
|
|
|
401
401
|
}
|
|
402
402
|
const writesByPath = /* @__PURE__ */ new Map();
|
|
403
403
|
async function pruneIfNeeded(filePath, opts) {
|
|
404
|
-
const stat = await
|
|
404
|
+
const stat = await fs$1.stat(filePath).catch(() => null);
|
|
405
405
|
if (!stat || stat.size <= opts.maxBytes) return;
|
|
406
|
-
const lines = (await
|
|
406
|
+
const lines = (await fs$1.readFile(filePath, "utf-8").catch(() => "")).split("\n").map((l) => l.trim()).filter(Boolean);
|
|
407
407
|
const kept = lines.slice(Math.max(0, lines.length - opts.keepLines));
|
|
408
408
|
const { randomBytes } = await import("node:crypto");
|
|
409
409
|
const tmp = `${filePath}.${process.pid}.${randomBytes(8).toString("hex")}.tmp`;
|
|
410
|
-
await
|
|
411
|
-
await
|
|
410
|
+
await fs$1.writeFile(tmp, `${kept.join("\n")}\n`, "utf-8");
|
|
411
|
+
await fs$1.rename(tmp, filePath);
|
|
412
412
|
}
|
|
413
413
|
async function appendCronRunLog(filePath, entry, opts) {
|
|
414
414
|
const resolved = path.resolve(filePath);
|
|
415
415
|
const next = (writesByPath.get(resolved) ?? Promise.resolve()).catch(() => void 0).then(async () => {
|
|
416
|
-
await
|
|
417
|
-
await
|
|
416
|
+
await fs$1.mkdir(path.dirname(resolved), { recursive: true });
|
|
417
|
+
await fs$1.appendFile(resolved, `${JSON.stringify(entry)}\n`, "utf-8");
|
|
418
418
|
await pruneIfNeeded(resolved, {
|
|
419
419
|
maxBytes: opts?.maxBytes ?? 2e6,
|
|
420
420
|
keepLines: opts?.keepLines ?? 2e3
|
|
@@ -426,7 +426,7 @@ async function appendCronRunLog(filePath, entry, opts) {
|
|
|
426
426
|
async function readCronRunLogEntries(filePath, opts) {
|
|
427
427
|
const limit = Math.max(1, Math.min(5e3, Math.floor(opts?.limit ?? 200)));
|
|
428
428
|
const jobId = opts?.jobId?.trim() || void 0;
|
|
429
|
-
const raw = await
|
|
429
|
+
const raw = await fs$1.readFile(path.resolve(filePath), "utf-8").catch(() => "");
|
|
430
430
|
if (!raw.trim()) return [];
|
|
431
431
|
const parsed = [];
|
|
432
432
|
const lines = raw.split("\n");
|
|
@@ -2938,7 +2938,7 @@ function resolveAgentWorkspaceFileOrRespondError(params, respond) {
|
|
|
2938
2938
|
}
|
|
2939
2939
|
async function statFile(filePath) {
|
|
2940
2940
|
try {
|
|
2941
|
-
const stat = await
|
|
2941
|
+
const stat = await fs$1.stat(filePath);
|
|
2942
2942
|
if (!stat.isFile()) return null;
|
|
2943
2943
|
return {
|
|
2944
2944
|
size: stat.size,
|
|
@@ -3008,7 +3008,7 @@ function resolveOptionalStringParam(value) {
|
|
|
3008
3008
|
async function moveToTrashBestEffort(pathname) {
|
|
3009
3009
|
if (!pathname) return;
|
|
3010
3010
|
try {
|
|
3011
|
-
await
|
|
3011
|
+
await fs$1.access(pathname);
|
|
3012
3012
|
} catch {
|
|
3013
3013
|
return;
|
|
3014
3014
|
}
|
|
@@ -3055,7 +3055,7 @@ const agentsHandlers = {
|
|
|
3055
3055
|
dir: workspaceDir,
|
|
3056
3056
|
ensureBootstrapFiles: !Boolean(nextConfig.agents?.defaults?.skipBootstrap)
|
|
3057
3057
|
});
|
|
3058
|
-
await
|
|
3058
|
+
await fs$1.mkdir(resolveSessionTranscriptsDirForAgent(agentId), { recursive: true });
|
|
3059
3059
|
await writeConfigFile(nextConfig);
|
|
3060
3060
|
const safeName = sanitizeIdentityLine(rawName);
|
|
3061
3061
|
const emoji = resolveOptionalStringParam(params.emoji);
|
|
@@ -3068,7 +3068,7 @@ const agentsHandlers = {
|
|
|
3068
3068
|
...avatar ? [`- Avatar: ${sanitizeIdentityLine(avatar)}`] : [],
|
|
3069
3069
|
""
|
|
3070
3070
|
];
|
|
3071
|
-
await
|
|
3071
|
+
await fs$1.appendFile(identityPath, lines.join("\n"), "utf-8");
|
|
3072
3072
|
respond(true, {
|
|
3073
3073
|
ok: true,
|
|
3074
3074
|
agentId,
|
|
@@ -3103,9 +3103,9 @@ const agentsHandlers = {
|
|
|
3103
3103
|
});
|
|
3104
3104
|
if (avatar) {
|
|
3105
3105
|
const workspace = workspaceDir ?? resolveAgentWorkspaceDir(nextConfig, agentId);
|
|
3106
|
-
await
|
|
3106
|
+
await fs$1.mkdir(workspace, { recursive: true });
|
|
3107
3107
|
const identityPath = path.join(workspace, DEFAULT_IDENTITY_FILENAME);
|
|
3108
|
-
await
|
|
3108
|
+
await fs$1.appendFile(identityPath, `\n- Avatar: ${sanitizeIdentityLine(avatar)}\n`, "utf-8");
|
|
3109
3109
|
}
|
|
3110
3110
|
respond(true, {
|
|
3111
3111
|
ok: true,
|
|
@@ -3188,7 +3188,7 @@ const agentsHandlers = {
|
|
|
3188
3188
|
}, void 0);
|
|
3189
3189
|
return;
|
|
3190
3190
|
}
|
|
3191
|
-
const content = await
|
|
3191
|
+
const content = await fs$1.readFile(filePath, "utf-8");
|
|
3192
3192
|
respond(true, {
|
|
3193
3193
|
agentId,
|
|
3194
3194
|
workspace: workspaceDir,
|
|
@@ -3210,10 +3210,10 @@ const agentsHandlers = {
|
|
|
3210
3210
|
const resolved = resolveAgentWorkspaceFileOrRespondError(params, respond);
|
|
3211
3211
|
if (!resolved) return;
|
|
3212
3212
|
const { agentId, workspaceDir, name } = resolved;
|
|
3213
|
-
await
|
|
3213
|
+
await fs$1.mkdir(workspaceDir, { recursive: true });
|
|
3214
3214
|
const filePath = path.join(workspaceDir, name);
|
|
3215
3215
|
const content = String(params.content ?? "");
|
|
3216
|
-
await
|
|
3216
|
+
await fs$1.writeFile(filePath, content, "utf-8");
|
|
3217
3217
|
const meta = await statFile(filePath);
|
|
3218
3218
|
respond(true, {
|
|
3219
3219
|
ok: true,
|
|
@@ -4201,7 +4201,7 @@ const chatHandlers = {
|
|
|
4201
4201
|
}
|
|
4202
4202
|
(async () => {
|
|
4203
4203
|
try {
|
|
4204
|
-
const [mod, { loadConfig }] = await Promise.all([import("./commands-registry-
|
|
4204
|
+
const [mod, { loadConfig }] = await Promise.all([import("./commands-registry-Ca5hh7nh.js").then((n) => n.t), import("./config-B4jkreCN.js").then((n) => n.t)]);
|
|
4205
4205
|
const cfg = loadConfig();
|
|
4206
4206
|
respond(true, { commands: mod.listChatCommandsForConfig(cfg).map((cmd) => ({
|
|
4207
4207
|
key: cmd.key,
|
|
@@ -4225,7 +4225,7 @@ const chatHandlers = {
|
|
|
4225
4225
|
}
|
|
4226
4226
|
(async () => {
|
|
4227
4227
|
try {
|
|
4228
|
-
const [{ createSymiTools }, { loadConfig }] = await Promise.all([import("./unified-runner-
|
|
4228
|
+
const [{ createSymiTools }, { loadConfig }] = await Promise.all([import("./unified-runner-CznU7Ad0.js").then((n) => n.C), import("./config-B4jkreCN.js").then((n) => n.t)]);
|
|
4229
4229
|
respond(true, { tools: createSymiTools({ config: loadConfig() }).map((tool) => {
|
|
4230
4230
|
const name = tool.name;
|
|
4231
4231
|
const description = tool.description;
|
|
@@ -4254,7 +4254,7 @@ const chatHandlers = {
|
|
|
4254
4254
|
}
|
|
4255
4255
|
(async () => {
|
|
4256
4256
|
try {
|
|
4257
|
-
const [{ listSkillCommandsForAgents }, { loadConfig }] = await Promise.all([import("./skill-commands-
|
|
4257
|
+
const [{ listSkillCommandsForAgents }, { loadConfig }] = await Promise.all([import("./skill-commands-DDGGlq68.js").then((n) => n.a), import("./config-B4jkreCN.js").then((n) => n.t)]);
|
|
4258
4258
|
respond(true, { items: listSkillCommandsForAgents({ cfg: loadConfig() }).map((skill) => ({
|
|
4259
4259
|
value: skill.name,
|
|
4260
4260
|
label: skill.description ? `${skill.name} — ${skill.description}` : skill.name
|
|
@@ -6542,7 +6542,7 @@ const docsHandlers = { "docs.get": async ({ params, respond }) => {
|
|
|
6542
6542
|
const fullPath = path.join(packageRoot, relPath);
|
|
6543
6543
|
let markdown;
|
|
6544
6544
|
try {
|
|
6545
|
-
markdown = await
|
|
6545
|
+
markdown = await fs$1.readFile(fullPath, "utf-8");
|
|
6546
6546
|
} catch (err) {
|
|
6547
6547
|
if (err?.code === "ENOENT") {
|
|
6548
6548
|
respond(false, void 0, errorShape(ErrorCodes.UNAVAILABLE, `docs file not bundled in this Symi install: ${relPath}`));
|
|
@@ -6693,14 +6693,14 @@ function isRollingLogFile(file) {
|
|
|
6693
6693
|
return ROLLING_LOG_RE.test(path.basename(file));
|
|
6694
6694
|
}
|
|
6695
6695
|
async function resolveLogFile(file) {
|
|
6696
|
-
if (await
|
|
6696
|
+
if (await fs$1.stat(file).catch(() => null)) return file;
|
|
6697
6697
|
if (!isRollingLogFile(file)) return file;
|
|
6698
6698
|
const dir = path.dirname(file);
|
|
6699
|
-
const entries = await
|
|
6699
|
+
const entries = await fs$1.readdir(dir, { withFileTypes: true }).catch(() => null);
|
|
6700
6700
|
if (!entries) return file;
|
|
6701
6701
|
return (await Promise.all(entries.filter((entry) => entry.isFile() && ROLLING_LOG_RE.test(entry.name)).map(async (entry) => {
|
|
6702
6702
|
const fullPath = path.join(dir, entry.name);
|
|
6703
|
-
const fileStat = await
|
|
6703
|
+
const fileStat = await fs$1.stat(fullPath).catch(() => null);
|
|
6704
6704
|
return fileStat ? {
|
|
6705
6705
|
path: fullPath,
|
|
6706
6706
|
mtimeMs: fileStat.mtimeMs
|
|
@@ -6708,7 +6708,7 @@ async function resolveLogFile(file) {
|
|
|
6708
6708
|
}))).filter((entry) => Boolean(entry)).toSorted((a, b) => b.mtimeMs - a.mtimeMs)[0]?.path ?? file;
|
|
6709
6709
|
}
|
|
6710
6710
|
async function readLogSlice(params) {
|
|
6711
|
-
const stat = await
|
|
6711
|
+
const stat = await fs$1.stat(params.file).catch(() => null);
|
|
6712
6712
|
if (!stat) return {
|
|
6713
6713
|
cursor: 0,
|
|
6714
6714
|
size: 0,
|
|
@@ -6746,7 +6746,7 @@ async function readLogSlice(params) {
|
|
|
6746
6746
|
truncated,
|
|
6747
6747
|
reset
|
|
6748
6748
|
};
|
|
6749
|
-
const handle = await
|
|
6749
|
+
const handle = await fs$1.open(params.file, "r");
|
|
6750
6750
|
try {
|
|
6751
6751
|
let prefix = "";
|
|
6752
6752
|
if (start > 0) {
|
|
@@ -7547,7 +7547,7 @@ const nodeHandlers = {
|
|
|
7547
7547
|
const p = params;
|
|
7548
7548
|
const payloadJSON = typeof p.payloadJSON === "string" ? p.payloadJSON : p.payload !== void 0 ? JSON.stringify(p.payload) : null;
|
|
7549
7549
|
await respondUnavailableOnThrow(respond, async () => {
|
|
7550
|
-
const { handleNodeEvent } = await import("./server-node-events-
|
|
7550
|
+
const { handleNodeEvent } = await import("./server-node-events-BKqszk_a.js");
|
|
7551
7551
|
const nodeId = client?.connect?.device?.id ?? client?.connect?.client?.id ?? "node";
|
|
7552
7552
|
await handleNodeEvent({
|
|
7553
7553
|
deps: context.deps,
|
|
@@ -8066,7 +8066,7 @@ function broadcastPresenceSnapshot(params) {
|
|
|
8066
8066
|
let _prevCpu = null;
|
|
8067
8067
|
function getCpuPercent() {
|
|
8068
8068
|
try {
|
|
8069
|
-
const parts = fs$
|
|
8069
|
+
const parts = fs$2.readFileSync("/proc/stat", "utf8").split("\n")[0].trim().split(/\s+/).slice(1).map(Number);
|
|
8070
8070
|
const [, , , idle, iowait] = parts;
|
|
8071
8071
|
const total = parts.reduce((a, b) => a + b, 0);
|
|
8072
8072
|
const active = total - idle - (iowait || 0);
|
|
@@ -8090,7 +8090,7 @@ function getCpuPercent() {
|
|
|
8090
8090
|
}
|
|
8091
8091
|
function getMemInfo() {
|
|
8092
8092
|
try {
|
|
8093
|
-
const text = fs$
|
|
8093
|
+
const text = fs$2.readFileSync("/proc/meminfo", "utf8");
|
|
8094
8094
|
const get = (key) => parseInt(text.match(new RegExp(`${key}:\\s+(\\d+)`))?.[1] ?? "0", 10) * 1024;
|
|
8095
8095
|
const total = get("MemTotal");
|
|
8096
8096
|
const used = total - get("MemAvailable");
|
|
@@ -8109,7 +8109,7 @@ function getMemInfo() {
|
|
|
8109
8109
|
}
|
|
8110
8110
|
function getDiskInfo() {
|
|
8111
8111
|
try {
|
|
8112
|
-
const stats = fs$
|
|
8112
|
+
const stats = fs$2.statfsSync("/");
|
|
8113
8113
|
const total = stats.blocks * stats.bsize;
|
|
8114
8114
|
const used = total - stats.bfree * stats.bsize;
|
|
8115
8115
|
return {
|
|
@@ -1,96 +1,96 @@
|
|
|
1
|
-
import { k as resolveOutboundTarget } from "./unified-runner-
|
|
1
|
+
import { k as resolveOutboundTarget } from "./unified-runner-CznU7Ad0.js";
|
|
2
2
|
import "./registry-Sbac4a4z.js";
|
|
3
3
|
import "./paths-By0XjHBk.js";
|
|
4
4
|
import "./utils-CTPsqyE_.js";
|
|
5
5
|
import { f as defaultRuntime } from "./subsystem-CHbO_DkH.js";
|
|
6
|
-
import "./auth-profiles-
|
|
6
|
+
import "./auth-profiles-Ce7R_25e.js";
|
|
7
7
|
import { s as normalizeMainKey } from "./session-key-DUSb7CCb.js";
|
|
8
8
|
import "./exec-DuYbft0z.js";
|
|
9
|
-
import { d as resolveSessionAgentId } from "./agent-scope-
|
|
10
|
-
import "./model-selection-
|
|
11
|
-
import "./file-lock-
|
|
9
|
+
import { d as resolveSessionAgentId } from "./agent-scope-DOrZjOnW.js";
|
|
10
|
+
import "./model-selection-7wdmO-Iw.js";
|
|
11
|
+
import "./file-lock-BVUYnlQv.js";
|
|
12
12
|
import "./agent-paths-BbZSGrUA.js";
|
|
13
|
-
import "./pi-embedded-helpers-
|
|
14
|
-
import { i as loadConfig } from "./config-
|
|
13
|
+
import "./pi-embedded-helpers-D-OFjhdI.js";
|
|
14
|
+
import { i as loadConfig } from "./config-B4jkreCN.js";
|
|
15
15
|
import "./boolean-CbZoNRMn.js";
|
|
16
16
|
import "./env-BRnPI9sO.js";
|
|
17
17
|
import "./shell-env-Dc3iU7HK.js";
|
|
18
18
|
import "./manifest-registry-D1MLZEjS.js";
|
|
19
|
-
import "./sandbox-
|
|
20
|
-
import "./chrome-
|
|
19
|
+
import "./sandbox-BkznAPKO.js";
|
|
20
|
+
import "./chrome-DJChpTwP.js";
|
|
21
21
|
import "./tailscale-DpKBMIvx.js";
|
|
22
22
|
import "./auth-Bkx-QuRN.js";
|
|
23
|
-
import "./server-context-
|
|
23
|
+
import "./server-context-ChcbJgNo.js";
|
|
24
24
|
import "./frontmatter-B_jqcova.js";
|
|
25
|
-
import "./skills-
|
|
26
|
-
import "./routes-
|
|
25
|
+
import "./skills-BwDmcZdt.js";
|
|
26
|
+
import "./routes-ivqbutvM.js";
|
|
27
27
|
import "./redact-B3O-RBO1.js";
|
|
28
28
|
import "./errors-bI7Tdx75.js";
|
|
29
|
-
import "./fs-safe-
|
|
30
|
-
import "./paths-
|
|
29
|
+
import "./fs-safe-BdejYjW8.js";
|
|
30
|
+
import "./paths-DObzwe08.js";
|
|
31
31
|
import "./ssrf-DOZRI5XH.js";
|
|
32
|
-
import "./image-ops-
|
|
33
|
-
import "./ports-
|
|
32
|
+
import "./image-ops-L70xVnpG.js";
|
|
33
|
+
import "./ports-gxLM5ahL.js";
|
|
34
34
|
import "./trash-_YhavPQI.js";
|
|
35
|
-
import { d as updateSessionStore } from "./sessions-
|
|
35
|
+
import { d as updateSessionStore } from "./sessions-Dxf5Kjig.js";
|
|
36
36
|
import "./dock-hF45sewN.js";
|
|
37
37
|
import "./message-channel-DgjXWzf-.js";
|
|
38
38
|
import { r as normalizeChannelId } from "./plugins-CF5skkHh.js";
|
|
39
|
-
import "./send-
|
|
39
|
+
import "./send-B0jHSNMF.js";
|
|
40
40
|
import "./paths-BtvQ7JvU.js";
|
|
41
41
|
import "./thinking-COroyVA5.js";
|
|
42
42
|
import "./tokens-0yh2UnJq.js";
|
|
43
|
-
import { t as deliverOutboundPayloads } from "./deliver-
|
|
43
|
+
import { t as deliverOutboundPayloads } from "./deliver-lTZLIQqf.js";
|
|
44
44
|
import "./diagnostic-DbT9t0Sh.js";
|
|
45
45
|
import "./diagnostic-session-state-DnkpMfCl.js";
|
|
46
|
-
import "./model-auth-
|
|
46
|
+
import "./model-auth-1EAQvYRv.js";
|
|
47
47
|
import "./github-copilot-token-D-FdDfee.js";
|
|
48
|
-
import "./models-config-
|
|
49
|
-
import "./pi-auth-json-
|
|
48
|
+
import "./models-config-B5Xxy-c-.js";
|
|
49
|
+
import "./pi-auth-json-Db8XJVGL.js";
|
|
50
50
|
import "./session-cost-usage-D3mgssM_.js";
|
|
51
|
-
import { C as enqueueSystemEvent, c as resolveGatewaySessionStoreTarget, o as loadSessionEntry, s as pruneLegacyStoreKeys } from "./session-utils-
|
|
52
|
-
import "./with-timeout-
|
|
53
|
-
import "./reply-prefix-
|
|
54
|
-
import "./memory-
|
|
55
|
-
import "./manager-
|
|
56
|
-
import "./sqlite-
|
|
51
|
+
import { C as enqueueSystemEvent, c as resolveGatewaySessionStoreTarget, o as loadSessionEntry, s as pruneLegacyStoreKeys } from "./session-utils-Cs1jlD-q.js";
|
|
52
|
+
import "./with-timeout-DPR4A2dx.js";
|
|
53
|
+
import "./reply-prefix-BFNeXT65.js";
|
|
54
|
+
import "./memory-B067LTL9.js";
|
|
55
|
+
import "./manager-CoCX7L5u.js";
|
|
56
|
+
import "./sqlite-Cod7C5ba.js";
|
|
57
57
|
import "./chunk-BxfKjCUx.js";
|
|
58
58
|
import "./markdown-tables-CS1Tvb3z.js";
|
|
59
59
|
import "./fetch-guard-JHxT9355.js";
|
|
60
|
-
import "./local-roots-
|
|
60
|
+
import "./local-roots-CgDCgCuM.js";
|
|
61
61
|
import "./commands-DUzLGgEZ.js";
|
|
62
|
-
import "./commands-registry-
|
|
63
|
-
import "./client-
|
|
64
|
-
import "./call-
|
|
65
|
-
import "./pairing-token-
|
|
62
|
+
import "./commands-registry-Ca5hh7nh.js";
|
|
63
|
+
import "./client-Cs9Bh-G0.js";
|
|
64
|
+
import "./call-xdEE97oU.js";
|
|
65
|
+
import "./pairing-token-Dcy37-4s.js";
|
|
66
66
|
import "./tool-display-DFOL6UQ9.js";
|
|
67
|
-
import "./skills-remote-
|
|
68
|
-
import "./workspace-dirs-
|
|
67
|
+
import "./skills-remote-bz71Bstn.js";
|
|
68
|
+
import "./workspace-dirs-jKFQf7of.js";
|
|
69
69
|
import "./pi-model-discovery-ClQLvlCW.js";
|
|
70
|
-
import "./model-catalog-
|
|
71
|
-
import "./skill-commands-
|
|
72
|
-
import "./pairing-store-
|
|
70
|
+
import "./model-catalog-IWi6-nY9.js";
|
|
71
|
+
import "./skill-commands-DDGGlq68.js";
|
|
72
|
+
import "./pairing-store-BNhJOnWn.js";
|
|
73
73
|
import "./exec-approvals-DioSaIeH.js";
|
|
74
|
-
import "./nodes-screen-
|
|
74
|
+
import "./nodes-screen-De9ma6e1.js";
|
|
75
75
|
import "./breakdown-B_Dhhm3K.js";
|
|
76
|
-
import "./control-service-
|
|
76
|
+
import "./control-service-D8kKOts5.js";
|
|
77
77
|
import "./stagger-DQs772BN.js";
|
|
78
78
|
import "./channel-selection-H1qOf0q-.js";
|
|
79
79
|
import "./delivery-queue-OAc7hsIs.js";
|
|
80
80
|
import "./bindings-DIhsYGa_.js";
|
|
81
|
-
import "./resolve-route-
|
|
81
|
+
import "./resolve-route-C1IIA6kH.js";
|
|
82
82
|
import "./links-Bqr0FxXx.js";
|
|
83
83
|
import "./cli-utils-CuyGL3rq.js";
|
|
84
84
|
import "./help-format-7hFcsqss.js";
|
|
85
85
|
import "./progress-swt2y17x.js";
|
|
86
|
-
import "./memory-cli-
|
|
86
|
+
import "./memory-cli-D8Z_5-Nz.js";
|
|
87
87
|
import "./logging-BWknayJl.js";
|
|
88
|
-
import "./replies-
|
|
89
|
-
import "./pi-tools.policy-
|
|
90
|
-
import "./model-
|
|
91
|
-
import "./deps-
|
|
92
|
-
import { c as parseMessageWithAttachments, l as formatForLog, r as registerApnsToken, s as normalizeRpcAttachmentsToChatAttachments } from "./push-apns-
|
|
93
|
-
import { t as agentCommand } from "./agent-
|
|
88
|
+
import "./replies-CbXXjn9X.js";
|
|
89
|
+
import "./pi-tools.policy-H2t-Xkfc.js";
|
|
90
|
+
import "./model-MUMSB_7d.js";
|
|
91
|
+
import "./deps-Bf9dt2UO.js";
|
|
92
|
+
import { c as parseMessageWithAttachments, l as formatForLog, r as registerApnsToken, s as normalizeRpcAttachmentsToChatAttachments } from "./push-apns-va-DRu4U.js";
|
|
93
|
+
import { t as agentCommand } from "./agent-CBfp75J4.js";
|
|
94
94
|
import { t as createOutboundSendDeps } from "./outbound-send-deps--SpwgFhS.js";
|
|
95
95
|
import { randomUUID } from "node:crypto";
|
|
96
96
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { c as resolveGatewayLaunchAgentLabel, f as resolveGatewayWindowsTaskName, p as resolveLegacyGatewayLaunchAgentLabels, t as GATEWAY_LAUNCH_AGENT_LABEL, u as resolveGatewayServiceDescription } from "./constants-BLIhifCJ.js";
|
|
2
|
-
import { _ as toPosixPath, a as readSystemdServiceRuntime, c as stopSystemdService, f as splitArgsPreservingQuotes, g as formatLine, h as resolveHomeDir, i as readSystemdServiceExecStart, l as uninstallSystemdService, m as resolveGatewayStateDir, n as isSystemdServiceEnabled, p as parseKeyValueOutput, s as restartSystemdService, t as installSystemdService, v as writeFormattedLines, y as execFileUtf8 } from "./systemd-
|
|
2
|
+
import { _ as toPosixPath, a as readSystemdServiceRuntime, c as stopSystemdService, f as splitArgsPreservingQuotes, g as formatLine, h as resolveHomeDir, i as readSystemdServiceExecStart, l as uninstallSystemdService, m as resolveGatewayStateDir, n as isSystemdServiceEnabled, p as parseKeyValueOutput, s as restartSystemdService, t as installSystemdService, v as writeFormattedLines, y as execFileUtf8 } from "./systemd-CUIM0n5P.js";
|
|
3
3
|
import path from "node:path";
|
|
4
|
-
import
|
|
4
|
+
import fs from "node:fs/promises";
|
|
5
5
|
|
|
6
6
|
//#region src/daemon/launchd-plist.ts
|
|
7
7
|
const plistEscape = (value) => value.replaceAll("&", "&").replaceAll("<", "<").replaceAll(">", ">").replaceAll("\"", """).replaceAll("'", "'");
|
|
@@ -14,7 +14,7 @@ const renderEnvDict = (env) => {
|
|
|
14
14
|
};
|
|
15
15
|
async function readLaunchAgentProgramArgumentsFromFile(plistPath) {
|
|
16
16
|
try {
|
|
17
|
-
const plist = await
|
|
17
|
+
const plist = await fs.readFile(plistPath, "utf8");
|
|
18
18
|
const programMatch = plist.match(/<key>ProgramArguments<\/key>\s*<array>([\s\S]*?)<\/array>/i);
|
|
19
19
|
if (!programMatch) return null;
|
|
20
20
|
const args = Array.from(programMatch[1].matchAll(/<string>([\s\S]*?)<\/string>/gi)).map((match) => plistUnescape(match[1] ?? "").trim());
|
|
@@ -128,7 +128,7 @@ async function isLaunchAgentListed(args) {
|
|
|
128
128
|
async function launchAgentPlistExists(env) {
|
|
129
129
|
try {
|
|
130
130
|
const plistPath = resolveLaunchAgentPlistPath(env);
|
|
131
|
-
await
|
|
131
|
+
await fs.access(plistPath);
|
|
132
132
|
return true;
|
|
133
133
|
} catch {
|
|
134
134
|
return false;
|
|
@@ -188,7 +188,7 @@ async function uninstallLaunchAgent({ env, stdout }) {
|
|
|
188
188
|
]);
|
|
189
189
|
await execLaunchctl(["unload", plistPath]);
|
|
190
190
|
try {
|
|
191
|
-
await
|
|
191
|
+
await fs.access(plistPath);
|
|
192
192
|
} catch {
|
|
193
193
|
stdout.write(`LaunchAgent not found at ${plistPath}\n`);
|
|
194
194
|
return;
|
|
@@ -197,8 +197,8 @@ async function uninstallLaunchAgent({ env, stdout }) {
|
|
|
197
197
|
const trashDir = path.join(home, ".Trash");
|
|
198
198
|
const dest = path.join(trashDir, `${label}.plist`);
|
|
199
199
|
try {
|
|
200
|
-
await
|
|
201
|
-
await
|
|
200
|
+
await fs.mkdir(trashDir, { recursive: true });
|
|
201
|
+
await fs.rename(plistPath, dest);
|
|
202
202
|
stdout.write(`${formatLine("Moved LaunchAgent to Trash", dest)}\n`);
|
|
203
203
|
} catch {
|
|
204
204
|
stdout.write(`LaunchAgent remains at ${plistPath} (could not move)\n`);
|
|
@@ -221,7 +221,7 @@ async function stopLaunchAgent({ stdout, env }) {
|
|
|
221
221
|
}
|
|
222
222
|
async function installLaunchAgent({ env, stdout, programArguments, workingDirectory, environment, description }) {
|
|
223
223
|
const { logDir, stdoutPath, stderrPath } = resolveGatewayLogPaths(env);
|
|
224
|
-
await
|
|
224
|
+
await fs.mkdir(logDir, { recursive: true });
|
|
225
225
|
const domain = resolveGuiDomain();
|
|
226
226
|
const label = resolveLaunchAgentLabel({ env });
|
|
227
227
|
for (const legacyLabel of resolveLegacyGatewayLaunchAgentLabels(env.SYMI_PROFILE)) {
|
|
@@ -233,11 +233,11 @@ async function installLaunchAgent({ env, stdout, programArguments, workingDirect
|
|
|
233
233
|
]);
|
|
234
234
|
await execLaunchctl(["unload", legacyPlistPath]);
|
|
235
235
|
try {
|
|
236
|
-
await
|
|
236
|
+
await fs.unlink(legacyPlistPath);
|
|
237
237
|
} catch {}
|
|
238
238
|
}
|
|
239
239
|
const plistPath = resolveLaunchAgentPlistPathForLabel(env, label);
|
|
240
|
-
await
|
|
240
|
+
await fs.mkdir(path.dirname(plistPath), { recursive: true });
|
|
241
241
|
const plist = buildLaunchAgentPlist({
|
|
242
242
|
label,
|
|
243
243
|
comment: resolveGatewayServiceDescription({
|
|
@@ -251,7 +251,7 @@ async function installLaunchAgent({ env, stdout, programArguments, workingDirect
|
|
|
251
251
|
stderrPath,
|
|
252
252
|
environment
|
|
253
253
|
});
|
|
254
|
-
await
|
|
254
|
+
await fs.writeFile(plistPath, plist, "utf8");
|
|
255
255
|
await execLaunchctl([
|
|
256
256
|
"bootout",
|
|
257
257
|
domain,
|
|
@@ -408,7 +408,7 @@ function resolveTaskUser(env) {
|
|
|
408
408
|
async function readScheduledTaskCommand(env) {
|
|
409
409
|
const scriptPath = resolveTaskScriptPath(env);
|
|
410
410
|
try {
|
|
411
|
-
const content = await
|
|
411
|
+
const content = await fs.readFile(scriptPath, "utf8");
|
|
412
412
|
let workingDirectory = "";
|
|
413
413
|
let commandLine = "";
|
|
414
414
|
const environment = {};
|
|
@@ -476,7 +476,7 @@ async function assertSchtasksAvailable() {
|
|
|
476
476
|
async function installScheduledTask({ env, stdout, programArguments, workingDirectory, environment, description }) {
|
|
477
477
|
await assertSchtasksAvailable();
|
|
478
478
|
const scriptPath = resolveTaskScriptPath(env);
|
|
479
|
-
await
|
|
479
|
+
await fs.mkdir(path.dirname(scriptPath), { recursive: true });
|
|
480
480
|
const script = buildTaskScript({
|
|
481
481
|
description: resolveGatewayServiceDescription({
|
|
482
482
|
env,
|
|
@@ -487,7 +487,7 @@ async function installScheduledTask({ env, stdout, programArguments, workingDire
|
|
|
487
487
|
workingDirectory,
|
|
488
488
|
environment
|
|
489
489
|
});
|
|
490
|
-
await
|
|
490
|
+
await fs.writeFile(scriptPath, script, "utf8");
|
|
491
491
|
const taskName = resolveTaskName(env);
|
|
492
492
|
const baseArgs = [
|
|
493
493
|
"/Create",
|
|
@@ -539,7 +539,7 @@ async function uninstallScheduledTask({ env, stdout }) {
|
|
|
539
539
|
]);
|
|
540
540
|
const scriptPath = resolveTaskScriptPath(env);
|
|
541
541
|
try {
|
|
542
|
-
await
|
|
542
|
+
await fs.unlink(scriptPath);
|
|
543
543
|
stdout.write(`${formatLine("Removed task script", scriptPath)}\n`);
|
|
544
544
|
} catch {
|
|
545
545
|
stdout.write(`Task script not found at ${scriptPath}\n`);
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import path from "node:path";
|
|
2
|
-
import
|
|
2
|
+
import fs from "node:fs/promises";
|
|
3
3
|
|
|
4
4
|
//#region src/agents/session-dirs.ts
|
|
5
5
|
async function resolveAgentSessionDirs(stateDir) {
|
|
6
6
|
const agentsDir = path.join(stateDir, "agents");
|
|
7
7
|
let entries = [];
|
|
8
8
|
try {
|
|
9
|
-
entries = await
|
|
9
|
+
entries = await fs.readdir(agentsDir, { withFileTypes: true });
|
|
10
10
|
} catch (err) {
|
|
11
11
|
if (err.code === "ENOENT") return [];
|
|
12
12
|
throw err;
|