openmeld 0.3.206 → 0.3.207
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/{add-me-membership-BkHWMxE4.js → add-me-membership-1JHMjZoR.js} +2 -2
- package/dist/{add-me-membership-BkHWMxE4.js.map → add-me-membership-1JHMjZoR.js.map} +1 -1
- package/dist/{agents-BOTlKiwS.js → agents-CIDsThyG.js} +150 -108
- package/dist/agents-CIDsThyG.js.map +1 -0
- package/dist/{api-client-foundation-6ms5gSu8.js → api-client-foundation-D6_NXHPV.js} +1 -1
- package/dist/{api-client-foundation-DpgDs0rw.js → api-client-foundation-DSurenul.js} +3 -3
- package/dist/{api-client-foundation-DpgDs0rw.js.map → api-client-foundation-DSurenul.js.map} +1 -1
- package/dist/auth-session-B7QMhHwh.js +4 -0
- package/dist/{auth-session-BjSqMLTz.js → auth-session-CO5XtFaq.js} +266 -75
- package/dist/auth-session-CO5XtFaq.js.map +1 -0
- package/dist/{base-url-CRAYNW-4.js → base-url-BE3pFiOZ.js} +1 -1
- package/dist/{base-url-9A557X2K.js → base-url-C6sHRNGu.js} +2 -2
- package/dist/{base-url-9A557X2K.js.map → base-url-C6sHRNGu.js.map} +1 -1
- package/dist/cli-binary-manifest-DiUulkp0.js +117 -0
- package/dist/cli-binary-manifest-DiUulkp0.js.map +1 -0
- package/dist/{command-CkbzbvXy.js → command-Bzt9zgnI.js} +13 -11
- package/dist/{command-CkbzbvXy.js.map → command-Bzt9zgnI.js.map} +1 -1
- package/dist/computer-connection-BOl79Ftf.js +54 -0
- package/dist/computer-connection-BOl79Ftf.js.map +1 -0
- package/dist/computer-connection-review-BTOvbJYL.js +39 -0
- package/dist/computer-connection-review-BTOvbJYL.js.map +1 -0
- package/dist/{computer-setup-continuation-Cd9nhLQ-.js → computer-setup-continuation-DmKdhR5u.js} +4 -4
- package/dist/{computer-setup-continuation-Cd9nhLQ-.js.map → computer-setup-continuation-DmKdhR5u.js.map} +1 -1
- package/dist/control-plane-D9jDcbMZ.js +1211 -0
- package/dist/control-plane-D9jDcbMZ.js.map +1 -0
- package/dist/daemon-local-state-file-jOXuXrky.js +45 -0
- package/dist/daemon-local-state-file-jOXuXrky.js.map +1 -0
- package/dist/daemon-runtime-lease-Dd4hdHNo.js +50 -0
- package/dist/daemon-runtime-lease-Dd4hdHNo.js.map +1 -0
- package/dist/{daemon-runtime-lease-BG9g0a6Z.js → daemon-runtime-lease-y3n1K0-C.js} +1 -1
- package/dist/{daemon-service-manager-DqVtRLBY.js → daemon-service-manager-Bh0LoLed.js} +1 -1
- package/dist/{daemon-service-manager-BVipiZwK.js → daemon-service-manager-GiMCiTmu.js} +99 -85
- package/dist/daemon-service-manager-GiMCiTmu.js.map +1 -0
- package/dist/daemon-service-runtime-DQW9gSLT.js +3642 -0
- package/dist/daemon-service-runtime-DQW9gSLT.js.map +1 -0
- package/dist/{daemon-state-BwIoDq7_.js → daemon-state-C37ZtIZK.js} +11 -5
- package/dist/daemon-state-C37ZtIZK.js.map +1 -0
- package/dist/{dist-CxadJClH.js → dist-D-kJdWZE.js} +726 -579
- package/dist/dist-D-kJdWZE.js.map +1 -0
- package/dist/dist-DTG_Vqc7.js +4 -0
- package/dist/distribution-DY2fBeSW.js +72 -0
- package/dist/distribution-DY2fBeSW.js.map +1 -0
- package/dist/{elapsed-time-C7P-nWIO.js → elapsed-time-CcoM2R3N.js} +7 -4
- package/dist/{elapsed-time-C7P-nWIO.js.map → elapsed-time-CcoM2R3N.js.map} +1 -1
- package/dist/{installation-inventory-P49sTjhe.js → installation-inventory-DJlwXa1q.js} +7 -6
- package/dist/{installation-inventory-P49sTjhe.js.map → installation-inventory-DJlwXa1q.js.map} +1 -1
- package/dist/{lock-CvBnBcFK.js → lock-Dxp6o_t_.js} +56 -7
- package/dist/lock-Dxp6o_t_.js.map +1 -0
- package/dist/{openmeld-ChOHuaqH.js → openmeld-CiL4AiB0.js} +226 -21
- package/dist/openmeld-CiL4AiB0.js.map +1 -0
- package/dist/openmeld-dev.js +1 -1
- package/dist/openmeld-environment-target-NtJYJe1D.js +256 -0
- package/dist/openmeld-environment-target-NtJYJe1D.js.map +1 -0
- package/dist/{openmeld-maintenance-worker-C7WykyDt.js → openmeld-maintenance-worker-DjdmRASI.js} +9 -8
- package/dist/{openmeld-maintenance-worker-C7WykyDt.js.map → openmeld-maintenance-worker-DjdmRASI.js.map} +1 -1
- package/dist/{openmeld-tools-update-coordinator-BBZhGo1A.js → openmeld-tools-update-coordinator-D9Skj8IE.js} +52 -4013
- package/dist/openmeld-tools-update-coordinator-D9Skj8IE.js.map +1 -0
- package/dist/openmeld.js +3 -3
- package/dist/{prepare-session-executor-CLmDoHom.js → prepare-session-executor-B0NtjHEL.js} +15 -13
- package/dist/{prepare-session-executor-CLmDoHom.js.map → prepare-session-executor-B0NtjHEL.js.map} +1 -1
- package/dist/{profiles-BCecj4Pj.js → runtime-transport-QIZmAo4-.js} +936 -2127
- package/dist/runtime-transport-QIZmAo4-.js.map +1 -0
- package/dist/service-account-authorization-Dt8kGvq8.js +56 -0
- package/dist/service-account-authorization-Dt8kGvq8.js.map +1 -0
- package/dist/service-control-capabilities-BU5F75zi.js +54 -0
- package/dist/service-control-capabilities-BU5F75zi.js.map +1 -0
- package/dist/service-control-capabilities-CzUB1ovW.js +4 -0
- package/dist/upgrade-DLECkjMt.js +4 -0
- package/dist/{upgrade-l_5Tge_z.js → upgrade-NxpTydHp.js} +6 -4
- package/dist/upgrade-NxpTydHp.js.map +1 -0
- package/package.json +2 -2
- package/dist/agents-BOTlKiwS.js.map +0 -1
- package/dist/auth-session-BjSqMLTz.js.map +0 -1
- package/dist/auth-session-ahQ5VXiF.js +0 -4
- package/dist/daemon-runtime-lease-CXlGR-iA.js +0 -87
- package/dist/daemon-runtime-lease-CXlGR-iA.js.map +0 -1
- package/dist/daemon-service-manager-BVipiZwK.js.map +0 -1
- package/dist/daemon-state-BwIoDq7_.js.map +0 -1
- package/dist/dist-0boZRalP.js +0 -4
- package/dist/dist-CxadJClH.js.map +0 -1
- package/dist/lock-CvBnBcFK.js.map +0 -1
- package/dist/openmeld-ChOHuaqH.js.map +0 -1
- package/dist/openmeld-tools-update-coordinator-BBZhGo1A.js.map +0 -1
- package/dist/profiles-BCecj4Pj.js.map +0 -1
- package/dist/upgrade-BKEAZKre.js +0 -4
- package/dist/upgrade-l_5Tge_z.js.map +0 -1
|
@@ -1,21 +1,29 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { c as toSpaceDispatchLookupUrl, h as toSpaceResultUrl, i as toSpaceContractUrl, l as toSpaceDispatchTraceUrl, r as toSpaceBoardUrl, t as normalizeBaseUrl } from "./urls-CY2uzH2-.js";
|
|
4
|
-
import {
|
|
4
|
+
import { A as isLocalMachineFailureError, D as createActiveSetupConcurrencyIssue, F as accountProfileSpaceCacheDir, I as accountProfileViewPath, M as formatLocalMachineIssueMessage, O as createOrphanedSetupConcurrencyIssue, Q as openMeldBackupsDir, R as accountsDir, T as LocalMachineFailureError, X as normalizeAccountKey, _ as resolveCliContext, _t as skillsDir, a as isOpenMeldOrphanedLockError, at as organizationSkillReleaseDir, b as formatLaneScopeSentence, c as releaseLockSync, d as runWithHeldLock, dt as resolveOpenMeldEnvPreset, et as openMeldManagedBinaryPath, ft as resolveOpenMeldRootDir, i as isOpenMeldLockError, j as toRecognizedLocalMachineFailureError, l as repairOrphanedLegacyLocks, m as OPENMELD_CLI_CONTEXT_ENV_KEY, ot as profileDir, p as LEGACY_OPENMELD_AGENT_SESSION_ENV_KEY, r as buildOpenMeldOrphanedLockAction, rt as openMeldRootDir, st as profileViewPath, t as acquireLock, tt as openMeldManagedVersionBinaryPath, u as resolveOpenMeldOrphanedLockIssue, ut as resolveOpenMeldCliEntryNameFromArgv, vt as spacesDir, w as readProcessStartIdentity, x as resolveOpenMeldLaneDescriptor, yt as systemDir } from "./lock-Dxp6o_t_.js";
|
|
5
|
+
import { $n as observabilityWakeTraceSelectorSchema, Bn as OPENMELD_HEADER_SPACE_ADDRESSING_VERSION, Bt as createFeedbackApi, Cn as toStructuredApiClientFailure, Cr as organizationSkillBundleSchema, Er as stringifyOrganizationSkillBundleCanonicalJson, Gn as pluginActionRequestSchema, Hr as agentActivitySessionStatusSchema, It as createComputerFileAccessApi, Jn as projectSpaceDispatchTraceFinalVisibleOutcome, Jr as resolvedSpaceMemberProfileSchema, Ln as OPENMELD_HEADER_PROFILE_ID, Mt as createAgentProfileBindingApi, Pt as createCenterAgentApi, Qn as spaceDispatchTraceResponseSchema, Qt as createPrepareReadinessApi, Rt as createCurrentDeviceApi, Ur as agentActivitySnapshotQuerySchema, Vr as agentActivityProviderSchema, Wn as spaceEntryTargetSchema, Xn as spaceDispatchTraceAttemptStatusSchema, Yn as resolveSpaceDispatchTraceRootCause, Yt as createOrganizationSkillsApi, Zn as spaceDispatchTraceDispatchStatusSchema, Zt as createPluginsApi, ei as agentActivityInventorySessionOriginSchema, er as projectObservabilityWakeCorrelation, fr as DEFAULT_AGENT_PROFILE_CREATION_CONFIGURATION, ii as localAgentSessionProviderSchema, ir as summarizeComputerFileAccessPolicy, jt as createAgentActivityApi, kr as submitFeedbackIssueRequestSchema, mr as createAgentProfileCreationRequestBodySchema, ni as agentActivitySessionInventoryQuerySchema, nr as ownerComputerDiagnosticsSchema, pr as agentProfileCreationConfigurationSchema, qn as SPACE_DISPATCH_TRACE_RESPONSE_CONTRACT_VERSION_HEADER, qt as createOrganizationApi, rn as createRoutinesApi, rr as projectOwnerComputerLocalRuntimes, ti as agentActivityInventorySessionStatusSchema, tn as createProjectsApi } from "./dist-D-kJdWZE.js";
|
|
5
6
|
import { c as agentControllerConversationRefSchema } from "./controller-contract-pe3_Re-c.js";
|
|
6
|
-
import { $ as formatDeviceReplyReadinessLabel, $
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import { $ as
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import { k as
|
|
17
|
-
import { C as
|
|
18
|
-
import { a as
|
|
7
|
+
import { $ as formatDeviceReplyReadinessLabel, $a as listOpenMeldProfiles, $r as resolveAgentControllerPermissionModeForController, At as createModelCatalogReadSession, Bt as setOpenMeldManagedProfileWorkspace, Ei as inspectDaemonServiceInventory, Fn as notifyDaemonRouteCatalogChanged, Ft as readProfileWorkspaceConfig, Gi as resolveRuntimeContext, Gr as getAgentControllerPermissionModeFieldLabel, Gt as bindProject, H as resolveDaemonServiceFreshnessWarning, Ha as requireOpenMeldProfile, Hi as buildOnboardingPlan, Hr as createAgentExecutionStatusDisplayRows, Ht as describeProfileWorkspacePathValidationFailure, Ja as setSelectedOpenMeldProfileId, Ji as setProfileDefaultView, Jr as parseAgentControllerRef, Jt as listProjectConnectionsWithStatus, Ka as clearSelectedOpenMeldProfileId, Ki as resolveViewProfileKey, Lt as resolveConfiguredProfileWorkspacePath, Mt as resolveProfileWorkspaceRuntime, Nt as ensureOpenMeldManagedProfileWorkspace, P as resolveServiceReadinessFromServiceStatus, Pt as normalizeCustomProfileWorkspacePath, Q as formatAgentReplyReadinessLabel, Qt as removeProjectConnection, Si as resolveDispatchSpaceActionMcpServer, Ua as resolveOpenMeldProfileOrNull, Ui as getSetupFlowCopy, Va as isSelectedOpenMeldProfileRequiredError, Vi as buildDaemonRouteObservationPresentation$1, Vt as validateCustomProfileWorkspacePath, Wa as alignSelectedOpenMeldProfileStorage, Wi as parseCliViewMode, Wr as getAgentControllerPermissionModeDisplayMetadata, Xa as createOpenMeldHumanProfile, Xr as projectPeopleComputersToLegacyLocalRuntimes, Ya as createOpenMeldAgentProfile, Yr as peopleComputerContainsDevice, Yt as migrateProjectBindingStore, Z as resolveCurrentReplyReadinessSnapshot, Za as deleteOpenMeldProfile, Zi as buildDaemonSystemServiceCommandSpec, ao as buildAgentAuthenticationGuide, ca as classifyDaemonServiceWakeability, cn as syncDeviceRuntimeStateProjection, co as buildHumanAuthenticationCard, d as isCliUpdateCheckApplicable, do as resolveAuthenticationGuidance, ei as resolveAgentExecutionStatus, en as runIfAgentActivityBindingGenerationIsCurrent, eo as primeOpenMeldProfilesSessionCache, et as formatHumanReplyReadinessReason$1, fn as createPrimaryBindingReadSession, fo as resolveAuthenticationGuidanceFromError, ft as resolveOpenClawLocalDiagnosticsValue, h as runPendingDaemonServiceUpdate, ho as compareAgentControllerRefsForDisplay, jn as listBuiltinAgentsRegistryEntries, kt as syncProfileWorkspaceState, l as readCurrentLocalDeviceId, lo as createAuthenticationError, lt as resolveGatewayChainReadiness, ni as resolveEvidenceSyncHealth, nn as unbindProject, no as updateOpenMeldProfile, nt as mapAgentReplyReadinessToLegacyAutoReply, o as assessServerRequiredVersion, pn as resolveAgentProfilePrimaryAgentControllerReport, po as resolveAuthenticationGuidanceFromMessage, qa as getSelectedOpenMeldProfileId, qi as getProfileDefaultView, qn as resolveLocalRegistryAgentIdFromAgentControllerRef, qr as listAgentControllerPermissionModeOptions, qt as listProjectBindings, ri as resolveNativeAgentControllerPermissionModeForController, rn as canonicalizeLocalProjectPath, sa as classifyDaemonServiceRunStartability, ti as resolveAgentProfileEditCapabilities, tn as setDefaultProjectConnection, to as resolveOpenMeldProfile, u as assessCliUpdate, vn as listAgentTargetStates, zi as resolveCurrentDaemonExpectedVersion, zt as setCustomProfileWorkspace } from "./openmeld-tools-update-coordinator-D9Skj8IE.js";
|
|
8
|
+
import { Ar as START_TRIMMED_NON_EMPTY_STRING_SCHEMA, Bn as resolveSpaceFileMimeType, Cn as centerAgentInteractionSourceSchema, Dr as START_BOUNDED_ID_SCHEMA, Fn as isSpaceFileTextEditable, Gr as openMeldProfileIdSchema, Jn as spaceFileEntryIdSchema, Kr as openMeldRequestContextSchema, Zn as spaceFileRevisionNumberSchema, at as spaceContractFieldsSchema, hr as spaceThreadContextSchema, ot as spaceContractSchema, rr as clientMessageIdSchema, wn as spaceStatusSchema, yn as messageEnvelopeSchema, zn as readSpaceFileTextResponseSchema } from "./runtime-transport-QIZmAo4-.js";
|
|
9
|
+
import { Dt as trimmedStringFromUnknown, Tt as nonEmptyTrimmedStringFromUnknown, b as dispatchExecutionSchema, gt as openMeldRuntimeProfileIdSchema } from "./control-plane-D9jDcbMZ.js";
|
|
10
|
+
import { A as withAuthSessionTransitionMutationLock, C as withAdmittedServiceSession, D as cancelServiceAccountAdmission, O as readServiceAccountAdmission, S as updateAuthSessionActiveOrganization, T as ServiceAccountAdmissionError, a as beginAuthSessionTransition, d as getCurrentAuthOwnerUserId, h as normalizeStoredActiveOrganization, k as reserveServiceAccountAdmission, l as getAuthSessionMetadata, n as AuthSessionRecoveryInProgressError, o as buildStoredAuthSessionIdentity, s as clearAuthSession, t as AuthSessionChangedBeforeTransitionError, u as getAuthSessionState, v as readServiceAdmissionSessionWithOwnership, w as runMacOsNativeKeychainHelperIfRequested } from "./auth-session-CO5XtFaq.js";
|
|
11
|
+
import { t as computerConnectionIntentSchema } from "./computer-connection-BOl79Ftf.js";
|
|
12
|
+
import { _ as readSelectedSkillDocument, f as ensureLocalSkills, n as collectSkillsReadinessSnapshot } from "./installation-inventory-DJlwXa1q.js";
|
|
13
|
+
import { $ as buildHumanErrorCopy, $n as uninstallAgentActivityIntegrations, $t as buildPublicSpaceEntryUrl, A as runDaemonBackgroundStartForDecision, Ar as cliJsonSkillsListEnvelopeSchema, B as runDaemonTeardownStrict, Bn as readAgentActivityOutboxHealth, C as resolveGatewayWebOrigin, Cr as finishCurrentCommandCheckScope, Ct as writeDispatchSpaceActionRecord, D as isManagedSystemServiceBootstrapRun, Dr as startCurrentCommandCheckScope, Dt as submitProfileRuntimeAgentControllerReport, E as bestEffortStopCurrentLaneDaemonService, Er as resetCurrentCommandCheckState, Et as readRuntimeReportingHealthState, F as runDaemonRunAfterEntryChecks, Fn as readCodexSessionTitles, Fr as organizationJoinLinkErrorResponseSchema, G as buildProfileWorkspacePresentation, Gn as registerAgentActivityRoute, H as formatServiceParticipationReadinessLabel, Hn as enqueueControllerTaskLifecycleEventWhileLocked, I as runDaemonServiceDetached, In as readAgentActivityContextForPath, Ir as organizationJoinLinkManagementQuerySchema, It as inspectSpaceCacheFile, J as createQuietPresenter, K as buildProfileWorkspaceRows, Kn as resolveAgentActivityRouteForPath, L as runDaemonSnapshot, Ln as removeAgentActivityContextCache, Lr as revokeOrganizationJoinLinkResponseSchema, M as runDaemonInstall, Mn as buildAgentActivityEvent, Mr as cliJsonSkillsShowEnvelopeSchema, N as runDaemonInterrupt, Nn as resolveObservedAgentActivityBinding, Nr as acceptOrganizationJoinLinkBodySchema, O as runDaemon, Or as cliJsonErrorEnvelopeSchema, Ot as submitRuntimeAgentControllerReport, P as runDaemonReinstall, Pn as normalizeSharedSessionTitle, Pr as getOrganizationJoinLinkResponseSchema, Q as runDaemonStartDecisionPrompt, Qn as resolveAgentActivityDispatcherCommand, Qt as buildDispatchResultReplyWorkflowProjection, R as runDaemonStatusFlow, Rn as enqueueAgentActivityHookEvent, Sr as runInteractivePrompt, St as readDispatchSpaceActionContextFromEnv, T as runDaemonServiceParticipationGate, Tr as isCurrentCommandCheckScopeActive, Tt as validateLocalProjectConnectionPath, Un as readControllerTaskLifecycleOutboxHealth, V as runDaemonUninstall, Vn as removeProjectOutbox, W as resolveServiceParticipationReadiness, Wn as isAgentActivityRouteRegistered, Xn as installAgentActivityIntegrations, Y as emitDaemonAgentOverview, Yn as defaultManagedIntegrationPaths, Z as shouldEmitAgentOverview, Zn as readAgentActivityIntegrationStatus, Zt as buildDispatchResultMessageReadProjection, _ as promptSearchSelect, _t as toStructuredGatewayFailure, a as runAgentsCustomRemove, ar as runAuthMenu, at as resolveLocalComponentsStatus, br as promptTextEntry, bt as readDispatchOwnedRuntimeGuard, c as runAgentsDisable, cn as buildUpdatesReplyWorkflowProjection, cr as buildAuthStatusRows, ct as fetchSpaceUpdates, d as runAgentsManage, dn as createSpaceMemberIdentityIndex, dr as renderInfoCard, dt as updateSpaceMeta, en as buildSignalIndex, er as buildCommandAuthenticationPromptMessage, et as renderHumanErrorCard, f as runAgentsRepair, fr as renderTextInfoCard, gt as readGatewayTextResponse, h as promptSearchMultiselect, hn as formatRemovedCcRelationMessage, hr as fetchAuthUserSnapshot, ht as readGatewayJsonResponse, i as runAgentsCustomList, ir as runAuthLogout, j as runDaemonCancel, jn as syncLocalAgentActivity, jr as cliJsonSkillsLoadEnvelopeSchema, k as runDaemonAutostart, kn as readRecentDaemonDispatchJournalEvents, kr as cliJsonOutputEnvelopeSchema, l as runAgentsEnable, lr as buildAuthStatusSnapshot, lt as createCliSpaceApi, m as formatTransportModeDisplay, n as runAgentsConfig, nr as evaluateCommandAuthentication, nt as emitCliJsonEnvelope, o as runAgentsCustomUpdate, or as runAuthStatus, ot as writeInstalledLocalComponentsSnapshot, p as runAgentsShow, q as reconcileCliVersionView, qn as unregisterAgentActivityRoute, qt as upsertSpaceConfig, r as runAgentsCustomAdd, rr as runAuthLogin, rt as runDaemonStartupPreflight, s as runAgentsDetect, sn as buildSpaceRoundReadProjection, sr as exchangeOneTimeTokenAuthSession, st as resolveDaemonServiceParticipationStatus, t as runAgents, tn as buildSignalMessageReadProjection, tr as ensureCommandAuthenticationOrCancel, tt as renderHumanTextErrorCard, u as runAgentsList, ur as formatActiveOrganizationLabel, ut as fetchSpaceMeta, vt as parseJsonResponse, w as resolveSpaceWebGatewayOrigin, wr as getCurrentCommandCheckState, wt as LocalProjectConnectionError, xr as isReturnKeypress, yt as assertDispatchOwnedRuntimePublicWriteAllowed, z as runDaemonStop, zn as removeProjectInbox } from "./agents-CIDsThyG.js";
|
|
14
|
+
import { a as serviceAccountControlRequestSchema, n as resolveOpenMeldDistribution, t as isBinaryDistribution } from "./distribution-DY2fBeSW.js";
|
|
15
|
+
import { r as readDaemonRuntimeLease } from "./daemon-runtime-lease-Dd4hdHNo.js";
|
|
16
|
+
import { Bt as readDaemonServiceContract, Mt as requestLocalAgentActivitySync, Pt as requestLocalDaemonShutdown, Vt as upsertDaemonServiceContract, X as buildInstallSelfJsonPayload, Z as performManagedInstall, jt as LocalDaemonControlPlaneClientError, lt as compareSemver, nt as OPENMELD_VERSION, r as readCurrentDaemonRuntimeContext, ut as ensureVersionStateReady } from "./daemon-service-runtime-DQW9gSLT.js";
|
|
17
|
+
import { $ as resolveCreateProfileName, A as parseEnvelope, B as resolveHumanControllerDisplayName, C as toSpaceMetaUpsertInput, D as formatHumanReadTargetList, E as buildHumanReplyContextSummary, F as resolveOpenMeldProfileForSpaceCommand, G as printOpenMeldBanner, H as resolveAgentProfileSetup, I as emitSpaceAgentOverview, J as renderOpenMeldLogo, K as renderOpenMeldBrandBlockLines, L as emitSpaceCliAgentOverview, M as assertFullSignalIdArgument, N as assertValidSpaceIdTarget, O as resolveLinkAccessLabel, P as prepareAuthenticatedSpaceCommandContext, Q as resolveCreateProfileKind, R as prepareLocalAgentReadiness, S as loadSpaceSignalIndexOrNull, T as buildFormalSignalReadPayload, U as colorizeAgentLabel, V as persistAgentTransportSelection, W as colorizeDisplayProfileLabel, X as resolveSpaceSendText, Y as renderOpenMeldTagline, Z as createProfileByKind, _ as runSpaceWriteWithPasswordRetry, a as runSpaceDelete, b as buildIdentityOnlyMembersSnapshotForReadProjection, c as runSpaceLeave, d as runSpaceRemoveMembers, et as ensureAgentProfileRuntimeBinding, f as runSpaceSend, g as runSpaceReadWithPasswordRetry, h as uploadPreparedSpaceFiles, i as runSpaceCreate, j as isSpaceCommandOutputHandledError, k as resolveOrganizationVisibilityLabel, l as runSpaceList, m as prepareRequestedSpaceSendFiles, n as promptAndConfirmSpacePassword, o as runSpaceHistory, p as runSpaceWatch, q as renderOpenMeldHeader, r as runSpaceAddMembers, s as runSpaceJoin, t as buildCreateSpacePasswordPromptConfig, tt as assessActionParticipationCandidate, u as runSpacePassword, v as buildHumanReadSignalsTranscriptItems, w as buildFormalDispatchResultReadPayload, x as loadSpaceIdentityDirectoryOrNull, y as emitHumanReadSignalsTextProjection, z as buildReplyReadinessGuidance } from "./command-Bzt9zgnI.js";
|
|
18
|
+
import { A as createSpaceMenuGuideError, Bt as formatDualViewGuideForDisplay, C as createSpaceAddMembersGuideError, F as createSpaceRemoveMembersGuideError, G as createStartAgentIdentityGuideError, H as createSpaceTargetGuideError, Ht as formatAgentOverviewPayload, I as createSpaceResultGuideError, It as registerBuiltinAgentSelectionOptions, J as OPENMELD_AGENT_MENTAL_MODEL_LINES, Jt as sanitizeTerminalDisplayText, K as createStartAuthenticationGuideError, M as createSpacePublicationSetGuideError, Ot as getCliVersionInfo, Q as areAllowedActionsEquivalent, Qt as outLine, T as createSpaceContractSetGuideError, Tt as registerSkillsTargetSelectionOptions, V as createSpaceSubcommandTargetGuideError, Vt as buildDualViewGuideMessage, W as createSpaceUpdatesGuideError, X as SPACE_CONTRACT_ALLOWED_ACTION_ORDER, Xt as errLine, Yt as formatMessage, Zt as outJsonLine, _ as createProfileActionGuideError, _t as registerSpaceMemberSelectionOptions, b as createResetConfirmationGuideError, bt as SPACE_ADD_MEMBERS_PROGRESS_HEARTBEAT_MS, et as buildAgentFacingPublicationModeGuideLines, g as createDoctorFailedGuideError, jt as registerAuthLoginRequestOptions, k as createSpaceLeaveGuideError, kt as registerDaemonControlTargetOptions, m as canUseInteractivePrompts, mt as getCommandHintsFromContract, ot as canonicalizeAllowedActions, qt as createPresenter, v as createProfileCreateGuideError, w as createSpaceAliasTargetGuideError, y as createProfileMenuGuideError, zt as DualViewGuideError } from "./elapsed-time-CcoM2R3N.js";
|
|
19
|
+
import { E as updateConfiguredStartV1OnboardingState, S as setConfiguredSkillsConfig, a as resolveBaseUrl, b as setConfiguredBaseUrl, c as resolveExplicitGatewayUrlOrThrow, g as getConfiguredSkillsConfig, m as getConfiguredOnboardingDisclaimerAcceptedAt, o as resolveBaseUrlOrNull, u as alignRuntimeConfigStorage, w as updateConfiguredOnboardingConfig } from "./base-url-C6sHRNGu.js";
|
|
20
|
+
import { A as getDaemonStatus, K as withDaemonServiceRunLock } from "./daemon-state-C37ZtIZK.js";
|
|
21
|
+
import { S as resolveDaemonServiceManager } from "./daemon-service-manager-GiMCiTmu.js";
|
|
22
|
+
import { a as formatOpenMeldCliCommand, c as formatOpenMeldCliTextBlock, d as resolveSetupFollowUpCliEntryCommand, f as resolveUserFacingCliEntryCommand, i as formatInlineOpenMeldCliCommands, o as formatOpenMeldCliCommands, r as resolveAuthBaseUrl, s as formatOpenMeldCliLine, t as resolveOpenMeldEnvironmentTarget, u as formatProfileAwareOpenMeldCliCommands } from "./openmeld-environment-target-NtJYJe1D.js";
|
|
23
|
+
import { n as resolveServiceAccountIdentity, r as runServiceAccountCarrier } from "./service-account-authorization-Dt8kGvq8.js";
|
|
24
|
+
import { c as buildRequestAuthHeaders, d as buildOpenMeldRequestContextFromProfile, n as fetchSpaceRequestWithTimeout, p as deriveAuthBaseUrlFromGatewayUrl, s as buildOpenMeldRequestContextHeadersWithAuth, t as createCliApiClientFoundation } from "./api-client-foundation-DSurenul.js";
|
|
25
|
+
import { C as buildNoLocalAgentsNoticeLines, D as recoverInterruptedComputerAuthHandoff, E as formatComputerAuthCleanupFailureSuffix, O as exchangeComputerAuthorizationGrant, S as buildLocalAgentsGuideUrl, T as emitUnusedSetupSessionCleanupWarning, _ as runStartLocalAgentsEnable, a as assertSetupServiceUpdateComplete, b as submitSelectedAgentControllerReports, c as collectObservedDeviceMetadata, d as collectStartLocalReadiness, f as runSkillsCheck$1, g as runSkillsUpdate, h as runSkillsUninstall, i as runPrepareSessionExecutor, j as writePrepareSessionSetupBootstrapResult, k as revokePreparedAuthSession, l as createSetupProgressReporter, m as runSkillsInstall, n as reportPrepareHandoffStopped, o as shouldForceSetupServiceRefresh, p as runSkillsEnsure, r as resolvePrepareSessionForHandoff, s as syncLocalSetupCurrentDeviceTargetFromServiceContract, t as connectPrepareSessionStream, u as resolveControllingTerminalSession, v as isCliOutputHandledError, w as confirmContinueWithoutLocalAgents, x as appendLocalAgentsGuideUrl, y as assertSelectedAgentControllerReportSubmissionsAccepted } from "./prepare-session-executor-B0NtjHEL.js";
|
|
26
|
+
import { a as runUpgrade, c as OPENMELD_UPGRADE_FAILURE_HINTS, l as OPENMELD_UPGRADE_METADATA_RECOVERY_HINTS, n as isUpgradeOutputHandledError, o as emitTopLevelAgentOverview, s as emitTopLevelCliAgentOverview, t as UPGRADE_INTERNAL_ALIGN_SERVICE_FLAG$1 } from "./upgrade-NxpTydHp.js";
|
|
19
27
|
import { createHash, randomUUID } from "node:crypto";
|
|
20
28
|
import { homedir, tmpdir } from "node:os";
|
|
21
29
|
import { basename, dirname, isAbsolute, join, relative, resolve } from "node:path";
|
|
@@ -26,8 +34,8 @@ import { constants, openAsBlob, readFileSync, realpathSync } from "node:fs";
|
|
|
26
34
|
import process$1 from "node:process";
|
|
27
35
|
import { execFile, spawn } from "node:child_process";
|
|
28
36
|
import { setTimeout as setTimeout$1 } from "node:timers/promises";
|
|
29
|
-
import pc from "picocolors";
|
|
30
37
|
import { promisify } from "node:util";
|
|
38
|
+
import pc from "picocolors";
|
|
31
39
|
import { cancel, confirm, intro, isCancel, multiselect, note, outro, select, spinner, text } from "@clack/prompts";
|
|
32
40
|
import { Command, Option } from "commander";
|
|
33
41
|
import { performance } from "node:perf_hooks";
|
|
@@ -11637,6 +11645,135 @@ function resolveRealPathOrNull$1(path) {
|
|
|
11637
11645
|
}
|
|
11638
11646
|
}
|
|
11639
11647
|
//#endregion
|
|
11648
|
+
//#region src/commands/service-account-control.ts
|
|
11649
|
+
function refused(reason, message) {
|
|
11650
|
+
throw new ServiceAccountAdmissionError(reason, message);
|
|
11651
|
+
}
|
|
11652
|
+
async function runServiceAccountControl(request) {
|
|
11653
|
+
const parsed = serviceAccountControlRequestSchema.safeParse(request);
|
|
11654
|
+
if (!parsed.success) refused("missing_account", "Choose a signed-in account before controlling this Service.");
|
|
11655
|
+
const input = parsed.data;
|
|
11656
|
+
if (process.platform === "win32") refused("unsupported_platform", "Account-checked Service control is not available on Windows yet.");
|
|
11657
|
+
const auth = await getAuthSessionState();
|
|
11658
|
+
if (auth.state !== "valid" || !auth.session) refused("authentication_required", "Sign in to the CLI with the matching account and try again.");
|
|
11659
|
+
const preparedSession = auth.session;
|
|
11660
|
+
if (preparedSession.user?.id !== input.expectedAccount) refused("account_mismatch", "The CLI is signed in to a different account. Sign in with the matching account and try again.");
|
|
11661
|
+
if ((await fetchAuthUserSnapshot({
|
|
11662
|
+
authBaseUrl: preparedSession.authBaseUrl,
|
|
11663
|
+
accessToken: preparedSession.accessToken
|
|
11664
|
+
})).id !== input.expectedAccount) refused("account_mismatch", "The CLI session belongs to a different account. Sign in again and retry.");
|
|
11665
|
+
await withDaemonServiceRunLock(async () => {
|
|
11666
|
+
const contract = await readDaemonServiceContract();
|
|
11667
|
+
if (!contract) refused("ownership_unknown", "Connect this computer through OpenMeld setup before controlling its Service.");
|
|
11668
|
+
const observed = await readCurrentDaemonRuntimeContext();
|
|
11669
|
+
const lease = await readDaemonRuntimeLease();
|
|
11670
|
+
if (input.operation === "start" && observed.effectiveRuntimeStatus !== "not_running") refused("busy", "The Service is already running or its state is uncertain. Check Service status before trying again.");
|
|
11671
|
+
if (input.operation === "stop" && (observed.effectiveRuntimeStatus !== "running" || !lease || lease.generation !== contract.generation)) refused("ownership_unknown", "OpenMeld could not verify the running Service. Check Service status before trying again.");
|
|
11672
|
+
let boundSession = preparedSession;
|
|
11673
|
+
const reservation = await withAuthSessionTransitionMutationLock(async () => {
|
|
11674
|
+
boundSession = await readServiceAdmissionSessionWithOwnership();
|
|
11675
|
+
if (boundSession.accessToken !== preparedSession.accessToken || boundSession.createdAt !== preparedSession.createdAt || boundSession.user?.id !== input.expectedAccount) refused("account_changed", "The CLI sign-in changed before this action was accepted. Check the account and try again.");
|
|
11676
|
+
const current = await readDaemonServiceContract();
|
|
11677
|
+
if (!current || JSON.stringify(current) !== JSON.stringify(contract)) refused("ownership_changed", "The Service changed before this action was accepted. Check its status and try again.");
|
|
11678
|
+
const identity = await resolveServiceAccountIdentity(boundSession, contract);
|
|
11679
|
+
if (input.operation === "start" && contract.desiredState !== "background") identity.contractGeneration += 1;
|
|
11680
|
+
return await reserveServiceAccountAdmission({
|
|
11681
|
+
operation: input.operation,
|
|
11682
|
+
identity,
|
|
11683
|
+
...input.operation === "stop" && lease ? { target: {
|
|
11684
|
+
ownerPid: lease.pid,
|
|
11685
|
+
ownerProcessStartedAt: readProcessStartIdentity(lease.pid) ?? refused("ownership_unknown", "OpenMeld could not identify the Service process. Check its status and try again.")
|
|
11686
|
+
} } : {}
|
|
11687
|
+
});
|
|
11688
|
+
});
|
|
11689
|
+
try {
|
|
11690
|
+
await withAdmittedServiceSession(boundSession, async () => {
|
|
11691
|
+
if (input.operation === "stop") {
|
|
11692
|
+
await stopReservedService(contract, reservation.id, lease?.pid ?? 0);
|
|
11693
|
+
return;
|
|
11694
|
+
}
|
|
11695
|
+
const manager = contract.serviceController === "legacy-detached" ? null : await resolveDaemonServiceManager(contract.serviceController);
|
|
11696
|
+
if (contract.serviceController !== "legacy-detached" && !(manager && (await manager.status()).installed)) refused("installation_required", "This Service needs setup before it can start. Run OpenMeld setup and try again.");
|
|
11697
|
+
await upsertDaemonServiceContract({
|
|
11698
|
+
...contract,
|
|
11699
|
+
desiredState: "background"
|
|
11700
|
+
});
|
|
11701
|
+
if (contract.serviceController === "legacy-detached") {
|
|
11702
|
+
const runtime = await resolveRuntimeContext({ view: "agent" });
|
|
11703
|
+
await runDaemonServiceDetached({
|
|
11704
|
+
accountAdmissionId: reservation.id,
|
|
11705
|
+
deviceId: contract.deviceId,
|
|
11706
|
+
gatewayUrl: contract.gatewayUrl,
|
|
11707
|
+
heartbeatMs: contract.heartbeatMs,
|
|
11708
|
+
runtime,
|
|
11709
|
+
presenter: createQuietPresenter(runtime),
|
|
11710
|
+
mode: "background"
|
|
11711
|
+
});
|
|
11712
|
+
} else if (manager) {
|
|
11713
|
+
await manager.deactivate();
|
|
11714
|
+
await manager.install(buildDaemonSystemServiceCommandSpec({
|
|
11715
|
+
controller: manager.controller,
|
|
11716
|
+
accountAdmissionId: reservation.id
|
|
11717
|
+
}));
|
|
11718
|
+
await manager.start();
|
|
11719
|
+
}
|
|
11720
|
+
await waitForAdmittedService(reservation.id);
|
|
11721
|
+
});
|
|
11722
|
+
} finally {
|
|
11723
|
+
await cancelServiceAccountAdmission(reservation.id);
|
|
11724
|
+
}
|
|
11725
|
+
});
|
|
11726
|
+
}
|
|
11727
|
+
async function waitForAdmittedService(id) {
|
|
11728
|
+
const deadline = Date.now() + 15e3;
|
|
11729
|
+
while (Date.now() < deadline) {
|
|
11730
|
+
const current = await readServiceAccountAdmission();
|
|
11731
|
+
const runtime = await readCurrentDaemonRuntimeContext();
|
|
11732
|
+
if (current?.id === id && current.state === "admitted" && current.carrier?.ownerPid === runtime.runtimeStatus.pid && runtime.effectiveRuntimeStatus === "running") return;
|
|
11733
|
+
await setTimeout$1(50);
|
|
11734
|
+
}
|
|
11735
|
+
refused("startup_unconfirmed", "OpenMeld could not confirm that this Service started. Check Service status before trying again.");
|
|
11736
|
+
}
|
|
11737
|
+
async function stopReservedService(contract, id, pid) {
|
|
11738
|
+
await requestAccountCheckedServiceStop({
|
|
11739
|
+
id,
|
|
11740
|
+
manager: contract.serviceController === "legacy-detached" ? null : await resolveDaemonServiceManager(contract.serviceController)
|
|
11741
|
+
});
|
|
11742
|
+
const admitted = await readServiceAccountAdmission();
|
|
11743
|
+
if (admitted?.id !== id || admitted.state !== "admitted" || admitted.carrier?.ownerPid !== pid) refused("admission_unconfirmed", "OpenMeld could not verify that the matching Service accepted Stop. Check Service status before trying again.");
|
|
11744
|
+
const current = await readCurrentDaemonRuntimeContext();
|
|
11745
|
+
if (current.runtimeStatus.pid !== null && current.runtimeStatus.pid !== pid) refused("ownership_changed", "Another Service instance is now running. Its state was left unchanged.");
|
|
11746
|
+
await runDaemonStop({
|
|
11747
|
+
json: true,
|
|
11748
|
+
view: "agent"
|
|
11749
|
+
}, { completedControlledShutdownOwnerPid: pid });
|
|
11750
|
+
}
|
|
11751
|
+
async function requestAccountCheckedServiceStop({ id, manager }) {
|
|
11752
|
+
const wasEnabled = manager ? (await manager.status()).enabled : false;
|
|
11753
|
+
if (manager) await manager.disableAutostart();
|
|
11754
|
+
try {
|
|
11755
|
+
if (!(await requestLocalDaemonShutdown({
|
|
11756
|
+
payload: {
|
|
11757
|
+
accountAdmissionId: id,
|
|
11758
|
+
mode: "graceful",
|
|
11759
|
+
gracePeriodMs: 2e3
|
|
11760
|
+
},
|
|
11761
|
+
timeoutMs: 15e3
|
|
11762
|
+
})).accepted) throw new Error("The Service did not confirm controlled shutdown.");
|
|
11763
|
+
} catch (error) {
|
|
11764
|
+
if (manager && wasEnabled && error instanceof LocalDaemonControlPlaneClientError && error.code === "service.account_admission.stop_refused") try {
|
|
11765
|
+
await manager.enableAutostart();
|
|
11766
|
+
} catch (restoreError) {
|
|
11767
|
+
throw new AggregateError([error, restoreError], "Stop was refused and its previous autostart setting could not be restored.");
|
|
11768
|
+
}
|
|
11769
|
+
if (!(error instanceof LocalDaemonControlPlaneClientError && error.code === "service.account_admission.stop_refused")) {
|
|
11770
|
+
const detail = error instanceof Error ? error.message : String(error);
|
|
11771
|
+
refused("stop_unconfirmed", `Stop may already be in progress. ${manager ? "Autostart remains disabled. " : ""}Check Service status before trying again. ${detail}`);
|
|
11772
|
+
}
|
|
11773
|
+
throw error;
|
|
11774
|
+
}
|
|
11775
|
+
}
|
|
11776
|
+
//#endregion
|
|
11640
11777
|
//#region src/config/space-dispatch-lookup-api.ts
|
|
11641
11778
|
async function fetchSpaceDispatchLookup(input) {
|
|
11642
11779
|
const endpoint = new URL(toSpaceDispatchLookupUrl(input.baseUrl, input.space));
|
|
@@ -14168,7 +14305,9 @@ async function runPreparedComputerAuthHandoff(input) {
|
|
|
14168
14305
|
ownerUserId: initialSnapshot.ownerUserId
|
|
14169
14306
|
});
|
|
14170
14307
|
const currentSession = await resolveCurrentComputerSession(candidate);
|
|
14308
|
+
await assertReviewedComputerConnection(input.connectionIntent, candidate, currentSession);
|
|
14171
14309
|
if (!await confirmComputerAccountSwitch({
|
|
14310
|
+
reviewedConnection: Boolean(input.connectionIntent),
|
|
14172
14311
|
candidate,
|
|
14173
14312
|
currentSession,
|
|
14174
14313
|
interactive: input.interactive,
|
|
@@ -14247,6 +14386,13 @@ async function runPreparedComputerAuthHandoff(input) {
|
|
|
14247
14386
|
stream.close();
|
|
14248
14387
|
}
|
|
14249
14388
|
}
|
|
14389
|
+
async function assertReviewedComputerConnection(review, candidate, currentSession) {
|
|
14390
|
+
if (!review) return;
|
|
14391
|
+
const intent = computerConnectionIntentSchema.safeParse(review);
|
|
14392
|
+
if (intent.success && intent.data.expectedAccount === candidate.user.id && intent.data.previousSessionIdentity === buildStoredAuthSessionIdentity(currentSession)) return;
|
|
14393
|
+
const revoked = await revokePreparedAuthSession(candidate);
|
|
14394
|
+
throw new Error(`The computer sign-in changed. Review the connection again before continuing.${formatComputerAuthCleanupFailureSuffix(revoked)}`);
|
|
14395
|
+
}
|
|
14250
14396
|
async function assertPrepareSessionOwner(input) {
|
|
14251
14397
|
if (input.candidate.user.id === input.ownerUserId) return;
|
|
14252
14398
|
const revoked = await revokePreparedAuthSession(input.candidate);
|
|
@@ -14308,6 +14454,7 @@ async function confirmComputerAccountSwitch(input) {
|
|
|
14308
14454
|
throw new Error(`OpenMeld could not verify the account currently connected to this Computer. The current Computer connection was not changed.${formatComputerAuthCleanupFailureSuffix(revoked)}`);
|
|
14309
14455
|
}
|
|
14310
14456
|
if (currentUserId === input.candidate.user.id) return true;
|
|
14457
|
+
if (input.reviewedConnection) return true;
|
|
14311
14458
|
const currentAccount = normalizeOptionalString$7(input.currentSession?.user?.email) ?? "the current account";
|
|
14312
14459
|
const nextAccount = normalizeOptionalString$7(input.candidate.user.email) ?? "another account";
|
|
14313
14460
|
if (!input.interactive || input.resolvedView !== "human") {
|
|
@@ -14389,6 +14536,7 @@ async function runSetupLocalAgentConnection(input) {
|
|
|
14389
14536
|
if (input.humanProfile) throw new Error(RETIRED_HUMAN_PROFILE_SETUP_MESSAGE);
|
|
14390
14537
|
const deviceCode = normalizeOptionalString$6(input.deviceCode);
|
|
14391
14538
|
if (input.startSession && deviceCode) return buildPrepareSessionSetupResult(await runComputerAuthorizationHandoff({
|
|
14539
|
+
connectionIntent: input.connectionIntent,
|
|
14392
14540
|
deviceCode,
|
|
14393
14541
|
interactive,
|
|
14394
14542
|
localAgentSelection: resolvePrepareSessionLocalAgentSelection(input),
|
|
@@ -24213,7 +24361,7 @@ function normalizeOptionalString(value) {
|
|
|
24213
24361
|
return normalized.length > 0 ? normalized : null;
|
|
24214
24362
|
}
|
|
24215
24363
|
async function runDefaultSpaceAddMeMembership(input) {
|
|
24216
|
-
const { runSpaceAddMeMembership } = await import("./add-me-membership-
|
|
24364
|
+
const { runSpaceAddMeMembership } = await import("./add-me-membership-1JHMjZoR.js");
|
|
24217
24365
|
return await runSpaceAddMeMembership(input);
|
|
24218
24366
|
}
|
|
24219
24367
|
//#endregion
|
|
@@ -28265,18 +28413,21 @@ withStartOptions(program.command("start").description("Initial onboarding: set u
|
|
|
28265
28413
|
}
|
|
28266
28414
|
});
|
|
28267
28415
|
});
|
|
28268
|
-
program.command("setup").description("Set up this computer for OpenMeld Space Wake.").option("--profile <id>", "Existing OpenMeld agent profile ID to connect to this computer").option("--agent <id...>", "Builtin local agent ID to repair directly when you already know the target").option("--human-profile <id>", "Retired OpenMeld Web setup flag; copy a fresh setup command from OpenMeld Web instead").option("--ott <token>", "One-time token to sign in on this device before setup").option("--device-code <code>", "Browser-approved code used to create this computer's independent sign-in session").option("--start-session <opaque-token>", "Continue an OpenMeld Web Prepare setup command on this device").option("--local-agents <mode>", "Select local agents during setup: all or none").option("--local-agent <id...>", "Select specific local agent IDs during setup").option("--reset-this-computer", "Stop stale local OpenMeld Service state before reconnecting this computer").addHelpText("after", buildCommandHelpExamples("Primary entry points", [
|
|
28416
|
+
program.command("setup").description("Set up this computer for OpenMeld Space Wake.").option("--connection-intent <json>", "Account and exact previous Computer session explicitly reviewed for this connection").option("--profile <id>", "Existing OpenMeld agent profile ID to connect to this computer").option("--agent <id...>", "Builtin local agent ID to repair directly when you already know the target").option("--human-profile <id>", "Retired OpenMeld Web setup flag; copy a fresh setup command from OpenMeld Web instead").option("--ott <token>", "One-time token to sign in on this device before setup").option("--device-code <code>", "Browser-approved code used to create this computer's independent sign-in session").option("--start-session <opaque-token>", "Continue an OpenMeld Web Prepare setup command on this device").option("--local-agents <mode>", "Select local agents during setup: all or none").option("--local-agent <id...>", "Select specific local agent IDs during setup").option("--reset-this-computer", "Stop stale local OpenMeld Service state before reconnecting this computer").addHelpText("after", buildCommandHelpExamples("Primary entry points", [
|
|
28269
28417
|
"openmeld setup",
|
|
28270
28418
|
"openmeld setup --start-session <opaque-token> --local-agents all",
|
|
28271
28419
|
"openmeld setup --profile <agent-profile-id> --local-agent <local-agent-id>"
|
|
28272
28420
|
])).action(async (opts) => {
|
|
28273
28421
|
const view = getGlobalViewOption();
|
|
28422
|
+
const connectionIntent = opts.connectionIntent ? computerConnectionIntentSchema.parse(JSON.parse(opts.connectionIntent)) : void 0;
|
|
28423
|
+
if (connectionIntent && !(opts.startSession && opts.deviceCode)) throw new Error("--connection-intent requires --start-session and --device-code.");
|
|
28274
28424
|
await runCommandWithEntryChecks({
|
|
28275
28425
|
routeTokens: ["setup"],
|
|
28276
28426
|
view,
|
|
28277
28427
|
profile: opts.profile,
|
|
28278
28428
|
run: async () => {
|
|
28279
28429
|
await runSetup({
|
|
28430
|
+
connectionIntent,
|
|
28280
28431
|
agent: opts.agent,
|
|
28281
28432
|
deviceCode: opts.deviceCode,
|
|
28282
28433
|
humanProfile: opts.humanProfile,
|
|
@@ -29329,8 +29480,8 @@ const serviceCmd = program.command("service").alias("daemon").description("Manag
|
|
|
29329
29480
|
}
|
|
29330
29481
|
});
|
|
29331
29482
|
});
|
|
29332
|
-
serviceCmd.command("start").description("Start OpenMeld Service on this device.").option("--mode <mode>", "Start mode: background (default) or foreground").option("--gateway-url <url>", "OpenMeld gateway URL (command line, OPENMELD_GATEWAY_URL, or saved OpenMeld settings)").option("--profile <id-or-name>", "Optional OpenMeld profile override used for owner resolution").option("--device-id <id>", "Override daemon device id for this run").option("--heartbeat-ms <n>", "Heartbeat interval in milliseconds (default: 25000)").option("--json", "Print machine-readable JSON.", false).action(runServiceStartCliAction);
|
|
29333
|
-
serviceCmd.command("run", { hidden: true }).description("Run OpenMeld Service in this process. System service entrypoint (launchd/systemd unit definitions call this); humans should use `openmeld service start`.").option("--mode <mode>", "Run mode: background (default) or foreground").option("--gateway-url <url>", "OpenMeld gateway URL (command line, OPENMELD_GATEWAY_URL, or saved OpenMeld settings)").option("--profile <id-or-name>", "Optional OpenMeld profile override used for owner resolution").option("--device-id <id>", "Override daemon device id for this run").option("--heartbeat-ms <n>", "Heartbeat interval in milliseconds (default: 25000)").action(runServiceStartCliAction);
|
|
29483
|
+
serviceCmd.command("start").description("Start OpenMeld Service on this device.").option("--expected-account <id>", "Require this signed-in account for Service control").option("--mode <mode>", "Start mode: background (default) or foreground").option("--gateway-url <url>", "OpenMeld gateway URL (command line, OPENMELD_GATEWAY_URL, or saved OpenMeld settings)").option("--profile <id-or-name>", "Optional OpenMeld profile override used for owner resolution").option("--device-id <id>", "Override daemon device id for this run").option("--heartbeat-ms <n>", "Heartbeat interval in milliseconds (default: 25000)").option("--json", "Print machine-readable JSON.", false).action(async (opts) => await runServiceStartCliAction(opts));
|
|
29484
|
+
serviceCmd.command("run", { hidden: true }).option("--account-admission-id <id>", "CLI-owned Service startup admission").description("Run OpenMeld Service in this process. System service entrypoint (launchd/systemd unit definitions call this); humans should use `openmeld service start`.").option("--mode <mode>", "Run mode: background (default) or foreground").option("--gateway-url <url>", "OpenMeld gateway URL (command line, OPENMELD_GATEWAY_URL, or saved OpenMeld settings)").option("--profile <id-or-name>", "Optional OpenMeld profile override used for owner resolution").option("--device-id <id>", "Override daemon device id for this run").option("--heartbeat-ms <n>", "Heartbeat interval in milliseconds (default: 25000)").action(async (opts) => await runServiceStartCliAction(opts));
|
|
29334
29485
|
serviceCmd.command("update-worker", { hidden: true }).description("Resume one durable OpenMeld Service update in the background.").action(async () => {
|
|
29335
29486
|
const result = await runPendingDaemonServiceUpdate();
|
|
29336
29487
|
if (result?.phase === "restored" || result?.phase === "needs_help") process.exitCode = 1;
|
|
@@ -29512,7 +29663,15 @@ serviceCmd.command("reinstall", { hidden: true }).description("Deprecated alias
|
|
|
29512
29663
|
errLine("hint: `openmeld service reinstall` is a deprecated alias; use `openmeld service repair`.");
|
|
29513
29664
|
await runServiceMaintenanceCliAction(opts, "repair");
|
|
29514
29665
|
});
|
|
29515
|
-
serviceCmd.command("stop").description("Stop OpenMeld Service on this device.").option("--force", "Send SIGKILL immediately instead of SIGTERM (human flow defaults to confirmation)").option("--profile <id-or-name>", "Optional OpenMeld profile override used for state sync").option("--json", "Print machine-readable JSON.", false).action(async (opts) => {
|
|
29666
|
+
serviceCmd.command("stop").description("Stop OpenMeld Service on this device.").option("--expected-account <id>", "Require this signed-in account for Service control").option("--force", "Send SIGKILL immediately instead of SIGTERM (human flow defaults to confirmation)").option("--profile <id-or-name>", "Optional OpenMeld profile override used for state sync").option("--json", "Print machine-readable JSON.", false).action(async (opts) => {
|
|
29667
|
+
if (opts.expectedAccount !== void 0) {
|
|
29668
|
+
if (!opts.json || opts.force || opts.profile) throw new Error("Account-bound Service control requires --json and does not accept force or profile overrides.");
|
|
29669
|
+
await runServiceAccountControl({
|
|
29670
|
+
operation: "stop",
|
|
29671
|
+
expectedAccount: opts.expectedAccount
|
|
29672
|
+
});
|
|
29673
|
+
return;
|
|
29674
|
+
}
|
|
29516
29675
|
const json = opts.json === true;
|
|
29517
29676
|
const view = getGlobalViewOption();
|
|
29518
29677
|
await runCommandWithEntryChecks({
|
|
@@ -29530,6 +29689,25 @@ serviceCmd.command("stop").description("Stop OpenMeld Service on this device.").
|
|
|
29530
29689
|
});
|
|
29531
29690
|
});
|
|
29532
29691
|
async function runServiceStartCliAction(opts) {
|
|
29692
|
+
if (opts.expectedAccount !== void 0) {
|
|
29693
|
+
if (!opts.json || opts.profile || opts.deviceId || opts.gatewayUrl || opts.heartbeatMs || opts.mode) throw new Error("Account-bound Service control requires --json and does not accept startup overrides.");
|
|
29694
|
+
await runServiceAccountControl({
|
|
29695
|
+
operation: "start",
|
|
29696
|
+
expectedAccount: opts.expectedAccount
|
|
29697
|
+
});
|
|
29698
|
+
emitCliJsonEnvelope({
|
|
29699
|
+
schemaVersion: 1,
|
|
29700
|
+
type: "daemon.run",
|
|
29701
|
+
ok: true,
|
|
29702
|
+
reason: "started"
|
|
29703
|
+
});
|
|
29704
|
+
return;
|
|
29705
|
+
}
|
|
29706
|
+
if (opts.accountAdmissionId) {
|
|
29707
|
+
const { accountAdmissionId, ...remaining } = opts;
|
|
29708
|
+
await runServiceAccountCarrier(accountAdmissionId, async () => await runServiceStartCliAction(remaining));
|
|
29709
|
+
return;
|
|
29710
|
+
}
|
|
29533
29711
|
const json = opts.json === true;
|
|
29534
29712
|
const view = getGlobalViewOption();
|
|
29535
29713
|
if (!json && shouldEmitAgentOverview({ resolvedView: view === "agent" ? "agent" : "human" })) emitDaemonAgentOverview({
|
|
@@ -31043,6 +31221,33 @@ async function handlePreParseStandaloneCommand(argv) {
|
|
|
31043
31221
|
async function main() {
|
|
31044
31222
|
if (await runMacOsNativeKeychainHelperIfRequested()) return;
|
|
31045
31223
|
const argv = process.argv.map((arg) => arg === "--h" ? "--help" : arg);
|
|
31224
|
+
if (argv.length === 5 && argv[2] === "computer" && argv[3] === "connection-review" && argv[4] === "--json") {
|
|
31225
|
+
const { readComputerConnectionReview } = await import("./computer-connection-review-BTOvbJYL.js");
|
|
31226
|
+
outLine(JSON.stringify(await readComputerConnectionReview()));
|
|
31227
|
+
return;
|
|
31228
|
+
}
|
|
31229
|
+
if (argv.length === 5 && argv[2] === "service" && argv[4] === "--json") {
|
|
31230
|
+
if (argv[3] === "control-carrier-capability") {
|
|
31231
|
+
outLine(JSON.stringify({
|
|
31232
|
+
protocol: "account-checked-service-control-v1",
|
|
31233
|
+
executable: process.execPath
|
|
31234
|
+
}));
|
|
31235
|
+
return;
|
|
31236
|
+
}
|
|
31237
|
+
if (argv[3] === "control-capabilities") {
|
|
31238
|
+
const { readServiceControlCapabilities } = await import("./service-control-capabilities-CzUB1ovW.js");
|
|
31239
|
+
emitCliJsonEnvelope({
|
|
31240
|
+
schemaVersion: 1,
|
|
31241
|
+
type: "service.control_capabilities",
|
|
31242
|
+
...await readServiceControlCapabilities().catch(() => ({
|
|
31243
|
+
deviceId: null,
|
|
31244
|
+
start: false,
|
|
31245
|
+
stop: false
|
|
31246
|
+
}))
|
|
31247
|
+
});
|
|
31248
|
+
return;
|
|
31249
|
+
}
|
|
31250
|
+
}
|
|
31046
31251
|
if (isDispatchSpaceActionToolServerArgv(argv)) {
|
|
31047
31252
|
await runSpaceActionMcpServer();
|
|
31048
31253
|
return;
|
|
@@ -31213,4 +31418,4 @@ main().catch((error) => {
|
|
|
31213
31418
|
//#endregion
|
|
31214
31419
|
export {};
|
|
31215
31420
|
|
|
31216
|
-
//# sourceMappingURL=openmeld-
|
|
31421
|
+
//# sourceMappingURL=openmeld-CiL4AiB0.js.map
|