aimux-cli 0.1.16 → 0.1.19
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/README.md +184 -67
- package/bin/aimux-dev +10 -0
- package/dist/agent-events.js +0 -1
- package/dist/agent-output-parser.js +0 -1
- package/dist/agent-prompt-delivery.js +0 -1
- package/dist/agent-tracker.js +0 -1
- package/dist/agent-watcher.js +0 -1
- package/dist/alert-display.d.ts +21 -0
- package/dist/alert-display.js +85 -0
- package/dist/atomic-write.js +0 -1
- package/dist/attachment-store.d.ts +0 -7
- package/dist/attachment-store.js +2 -87
- package/dist/builtin-metadata-watchers.js +4 -5
- package/dist/claude-hooks.d.ts +1 -0
- package/dist/claude-hooks.js +25 -1
- package/dist/config.d.ts +19 -13
- package/dist/config.js +28 -15
- package/dist/connection-targets.d.ts +8 -0
- package/dist/connection-targets.js +27 -0
- package/dist/context/compactor.js +0 -1
- package/dist/context/context-bridge.js +0 -1
- package/dist/context/context-file.js +0 -1
- package/dist/context/history.js +0 -1
- package/dist/credentials.d.ts +12 -0
- package/dist/credentials.js +48 -0
- package/dist/daemon.d.ts +23 -0
- package/dist/daemon.js +391 -67
- package/dist/dashboard/command-spec.js +0 -1
- package/dist/dashboard/feedback.js +0 -1
- package/dist/dashboard/index.d.ts +13 -10
- package/dist/dashboard/index.js +3 -27
- package/dist/dashboard/operation-failures.js +0 -1
- package/dist/dashboard/order.d.ts +22 -0
- package/dist/dashboard/order.js +54 -0
- package/dist/dashboard/pending-actions.d.ts +39 -10
- package/dist/dashboard/pending-actions.js +166 -37
- package/dist/dashboard/quick-jump.d.ts +2 -1
- package/dist/dashboard/quick-jump.js +7 -5
- package/dist/dashboard/runtime-evidence.js +0 -1
- package/dist/dashboard/session-actions.d.ts +4 -4
- package/dist/dashboard/session-actions.js +1 -2
- package/dist/dashboard/session-registry.d.ts +4 -3
- package/dist/dashboard/session-registry.js +16 -51
- package/dist/dashboard/sort.js +0 -1
- package/dist/dashboard/state.d.ts +1 -1
- package/dist/dashboard/state.js +0 -1
- package/dist/dashboard/targets.js +0 -1
- package/dist/dashboard/ui-state-store.d.ts +16 -1
- package/dist/dashboard/ui-state-store.js +73 -3
- package/dist/debug-state.d.ts +97 -0
- package/dist/debug-state.js +540 -0
- package/dist/debug.d.ts +38 -0
- package/dist/debug.js +219 -16
- package/dist/default-plugins/gh-pr-context.d.ts +2 -1
- package/dist/default-plugins/gh-pr-context.js +17 -12
- package/dist/default-plugins/transcript-length.js +15 -3
- package/dist/fast-control.js +37 -20
- package/dist/hotkeys.js +0 -1
- package/dist/http-client.js +31 -3
- package/dist/key-parser.js +0 -1
- package/dist/last-used.js +0 -1
- package/dist/local-ui-server.d.ts +22 -0
- package/dist/local-ui-server.js +185 -0
- package/dist/login-flow.d.ts +7 -0
- package/dist/login-flow.js +119 -0
- package/dist/main.js +821 -152
- package/dist/managed-launch-env.js +14 -1
- package/dist/metadata-server.d.ts +36 -36
- package/dist/metadata-server.js +638 -138
- package/dist/metadata-store.d.ts +4 -1
- package/dist/metadata-store.js +30 -3
- package/dist/multiplexer/agent-io-methods.d.ts +2 -10
- package/dist/multiplexer/agent-io-methods.js +12 -44
- package/dist/multiplexer/archives.js +8 -10
- package/dist/multiplexer/dashboard-actions-methods.js +0 -1
- package/dist/multiplexer/dashboard-control.js +45 -14
- package/dist/multiplexer/dashboard-interaction.d.ts +8 -2
- package/dist/multiplexer/dashboard-interaction.js +187 -29
- package/dist/multiplexer/dashboard-model.d.ts +10 -3
- package/dist/multiplexer/dashboard-model.js +417 -36
- package/dist/multiplexer/dashboard-ops.d.ts +9 -7
- package/dist/multiplexer/dashboard-ops.js +178 -69
- package/dist/multiplexer/dashboard-state-methods.d.ts +2 -1
- package/dist/multiplexer/dashboard-state-methods.js +3 -3
- package/dist/multiplexer/dashboard-tail-methods.d.ts +22 -10
- package/dist/multiplexer/dashboard-tail-methods.js +164 -48
- package/dist/multiplexer/dashboard-view-methods.d.ts +1 -1
- package/dist/multiplexer/dashboard-view-methods.js +23 -9
- package/dist/multiplexer/graveyard-view-model.d.ts +9 -1
- package/dist/multiplexer/graveyard-view-model.js +39 -1
- package/dist/multiplexer/index.d.ts +15 -12
- package/dist/multiplexer/index.js +64 -44
- package/dist/multiplexer/navigation.js +0 -1
- package/dist/multiplexer/notifications.js +107 -25
- package/dist/multiplexer/persistence-methods.d.ts +31 -4
- package/dist/multiplexer/persistence-methods.js +304 -309
- package/dist/multiplexer/runtime-lifecycle-methods.d.ts +8 -10
- package/dist/multiplexer/runtime-lifecycle-methods.js +104 -87
- package/dist/multiplexer/runtime-state.d.ts +8 -10
- package/dist/multiplexer/runtime-state.js +82 -146
- package/dist/multiplexer/runtime-sync.d.ts +2 -10
- package/dist/multiplexer/runtime-sync.js +3 -19
- package/dist/multiplexer/service-state-snapshot.d.ts +2 -4
- package/dist/multiplexer/service-state-snapshot.js +4 -52
- package/dist/multiplexer/services.d.ts +1 -0
- package/dist/multiplexer/services.js +55 -6
- package/dist/multiplexer/session-capture.d.ts +1 -0
- package/dist/multiplexer/session-capture.js +23 -0
- package/dist/multiplexer/session-launch.d.ts +4 -1
- package/dist/multiplexer/session-launch.js +152 -64
- package/dist/multiplexer/session-runtime-core.d.ts +8 -20
- package/dist/multiplexer/session-runtime-core.js +40 -136
- package/dist/multiplexer/subscreens.js +10 -4
- package/dist/multiplexer/tool-picker.js +0 -1
- package/dist/multiplexer/worktree-graveyard.d.ts +0 -1
- package/dist/multiplexer/worktree-graveyard.js +15 -17
- package/dist/multiplexer/worktrees.js +96 -41
- package/dist/notification-context.js +8 -5
- package/dist/notifications.js +163 -102
- package/dist/notify.d.ts +4 -0
- package/dist/notify.js +14 -1
- package/dist/orchestration-actions.js +0 -1
- package/dist/orchestration-routing.js +0 -1
- package/dist/orchestration.js +0 -1
- package/dist/osc-notifications.js +0 -1
- package/dist/paths.d.ts +32 -7
- package/dist/paths.js +82 -59
- package/dist/pending-actions.d.ts +5 -0
- package/dist/pending-actions.js +13 -0
- package/dist/plugin-runtime.js +9 -3
- package/dist/project-events.d.ts +1 -10
- package/dist/project-events.js +0 -11
- package/dist/project-scanner.d.ts +2 -3
- package/dist/project-scanner.js +58 -130
- package/dist/project-service-manifest.d.ts +1 -3
- package/dist/project-service-manifest.js +1 -4
- package/dist/recency.js +0 -1
- package/dist/recorder.js +0 -1
- package/dist/relay-client.d.ts +30 -0
- package/dist/relay-client.js +190 -0
- package/dist/remote-access.d.ts +16 -0
- package/dist/remote-access.js +90 -0
- package/dist/runtime-core/exchange-derived.d.ts +2 -0
- package/dist/runtime-core/exchange-derived.js +153 -0
- package/dist/runtime-core/exchange-import.d.ts +24 -0
- package/dist/runtime-core/exchange-import.js +317 -0
- package/dist/runtime-core/exchange-store.d.ts +157 -0
- package/dist/runtime-core/exchange-store.js +452 -0
- package/dist/runtime-core/topology-services.d.ts +38 -0
- package/dist/runtime-core/topology-services.js +170 -0
- package/dist/runtime-core/topology-sessions.d.ts +52 -0
- package/dist/runtime-core/topology-sessions.js +238 -0
- package/dist/runtime-core/topology-store.d.ts +171 -0
- package/dist/runtime-core/topology-store.js +419 -0
- package/dist/runtime-core/topology-worktrees.d.ts +60 -0
- package/dist/runtime-core/topology-worktrees.js +199 -0
- package/dist/runtime-migration.d.ts +69 -0
- package/dist/runtime-migration.js +398 -0
- package/dist/session-bootstrap.d.ts +8 -6
- package/dist/session-bootstrap.js +51 -159
- package/dist/session-runtime.d.ts +2 -0
- package/dist/session-runtime.js +1 -1
- package/dist/session-semantics.d.ts +12 -4
- package/dist/session-semantics.js +14 -1
- package/dist/shell-args.js +0 -1
- package/dist/shell-hooks.js +32 -11
- package/dist/shell-state.d.ts +2 -0
- package/dist/shell-state.js +26 -2
- package/dist/status-detector.js +0 -1
- package/dist/statusline-model.d.ts +10 -2
- package/dist/statusline-model.js +106 -31
- package/dist/task-workflow.d.ts +6 -9
- package/dist/task-workflow.js +37 -85
- package/dist/tasks.d.ts +6 -33
- package/dist/tasks.js +46 -89
- package/dist/team.d.ts +29 -0
- package/dist/team.js +40 -1
- package/dist/terminal-host.js +0 -1
- package/dist/threads.d.ts +6 -35
- package/dist/threads.js +89 -99
- package/dist/tmux/doctor.js +0 -1
- package/dist/tmux/inbox-popup.js +37 -16
- package/dist/tmux/runtime-manager.d.ts +3 -0
- package/dist/tmux/runtime-manager.js +21 -5
- package/dist/tmux/session-transport.js +0 -1
- package/dist/tmux/statusline-cache.js +0 -1
- package/dist/tmux/statusline.js +49 -10
- package/dist/tmux/switcher.js +0 -1
- package/dist/tmux/window-open.js +1 -3
- package/dist/tool-output-watchers.d.ts +0 -18
- package/dist/tool-output-watchers.js +0 -323
- package/dist/tui/render/box.js +0 -1
- package/dist/tui/render/text.js +0 -1
- package/dist/tui/screens/dashboard-renderers.js +37 -26
- package/dist/tui/screens/overlay-renderers.d.ts +2 -0
- package/dist/tui/screens/overlay-renderers.js +37 -2
- package/dist/tui/screens/subscreen-renderers.js +7 -1
- package/dist/workflow.js +0 -1
- package/dist/worktree.js +17 -1
- package/dist-ui/_expo/static/css/web-30453ede1678c16acb08b97e83e8646d.css +1 -0
- package/dist-ui/_expo/static/js/web/entry-477c745b2adc79367a4380ecf07d9ff6.js +14620 -0
- package/dist-ui/assets/assets/images/icon.a5413dcd2e811c9f2317d01a28118d8a.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/back-icon-mask.0a328cd9c1afd0afe8e3b1ec5165b1b4.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/back-icon.35ba0eaec5a4f5ed12ca16fabeae451d.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@2x.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@3x.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@4x.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/close-icon.808e1b1b9b53114ec2838071a7e6daa7.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/close-icon.808e1b1b9b53114ec2838071a7e6daa7@2x.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/close-icon.808e1b1b9b53114ec2838071a7e6daa7@3x.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/close-icon.808e1b1b9b53114ec2838071a7e6daa7@4x.png +0 -0
- package/dist-ui/assets/node_modules/@react-navigation/elements/lib/module/assets/search-icon.286d67d3f74808a60a78d3ebf1a5fb57.png +0 -0
- package/dist-ui/assets/node_modules/expo-router/assets/arrow_down.017bc6ba3fc25503e5eb5e53826d48a8.png +0 -0
- package/dist-ui/assets/node_modules/expo-router/assets/error.d1ea1496f9057eb392d5bbf3732a61b7.png +0 -0
- package/dist-ui/assets/node_modules/expo-router/assets/file.19eeb73b9593a38f8e9f418337fc7d10.png +0 -0
- package/dist-ui/assets/node_modules/expo-router/assets/forward.d8b800c443b8972542883e0b9de2bdc6.png +0 -0
- package/dist-ui/assets/node_modules/expo-router/assets/pkg.ab19f4cbc543357183a20571f68380a3.png +0 -0
- package/dist-ui/assets/node_modules/expo-router/assets/sitemap.412dd9275b6b48ad28f5e3d81bb1f626.png +0 -0
- package/dist-ui/assets/node_modules/expo-router/assets/unmatched.20e71bdf79e3a97bf55fd9e164041578.png +0 -0
- package/dist-ui/favicon.ico +0 -0
- package/dist-ui/index.html +38 -0
- package/dist-ui/metadata.json +1 -0
- package/package.json +29 -12
- package/dist/agent-events.js.map +0 -1
- package/dist/agent-message-parts.d.ts +0 -17
- package/dist/agent-message-parts.js +0 -31
- package/dist/agent-message-parts.js.map +0 -1
- package/dist/agent-output-parser.js.map +0 -1
- package/dist/agent-prompt-delivery.js.map +0 -1
- package/dist/agent-tracker.js.map +0 -1
- package/dist/agent-watcher.js.map +0 -1
- package/dist/atomic-write.js.map +0 -1
- package/dist/attachment-store.js.map +0 -1
- package/dist/builtin-metadata-watchers.js.map +0 -1
- package/dist/claude-hooks.js.map +0 -1
- package/dist/config.js.map +0 -1
- package/dist/context/compactor.js.map +0 -1
- package/dist/context/context-bridge.js.map +0 -1
- package/dist/context/context-file.js.map +0 -1
- package/dist/context/history.js.map +0 -1
- package/dist/daemon.js.map +0 -1
- package/dist/dashboard/command-spec.js.map +0 -1
- package/dist/dashboard/feedback.js.map +0 -1
- package/dist/dashboard/index.js.map +0 -1
- package/dist/dashboard/operation-failures.js.map +0 -1
- package/dist/dashboard/pending-actions.js.map +0 -1
- package/dist/dashboard/quick-jump.js.map +0 -1
- package/dist/dashboard/runtime-evidence.js.map +0 -1
- package/dist/dashboard/session-actions.js.map +0 -1
- package/dist/dashboard/session-registry.js.map +0 -1
- package/dist/dashboard/sort.js.map +0 -1
- package/dist/dashboard/state.js.map +0 -1
- package/dist/dashboard/targets.js.map +0 -1
- package/dist/dashboard/ui-state-store.js.map +0 -1
- package/dist/debug.js.map +0 -1
- package/dist/default-plugins/gh-pr-context.js.map +0 -1
- package/dist/default-plugins/transcript-length.js.map +0 -1
- package/dist/fast-control.js.map +0 -1
- package/dist/hotkeys.js.map +0 -1
- package/dist/http-client.js.map +0 -1
- package/dist/instance-directory.d.ts +0 -32
- package/dist/instance-directory.js +0 -82
- package/dist/instance-directory.js.map +0 -1
- package/dist/instance-registry.d.ts +0 -39
- package/dist/instance-registry.js +0 -208
- package/dist/instance-registry.js.map +0 -1
- package/dist/key-parser.js.map +0 -1
- package/dist/last-used.js.map +0 -1
- package/dist/main.js.map +0 -1
- package/dist/managed-launch-env.js.map +0 -1
- package/dist/metadata-server.js.map +0 -1
- package/dist/metadata-store.js.map +0 -1
- package/dist/multiplexer/agent-io-methods.js.map +0 -1
- package/dist/multiplexer/archives.js.map +0 -1
- package/dist/multiplexer/dashboard-actions-methods.js.map +0 -1
- package/dist/multiplexer/dashboard-control.js.map +0 -1
- package/dist/multiplexer/dashboard-interaction.js.map +0 -1
- package/dist/multiplexer/dashboard-model.js.map +0 -1
- package/dist/multiplexer/dashboard-ops.js.map +0 -1
- package/dist/multiplexer/dashboard-state-methods.js.map +0 -1
- package/dist/multiplexer/dashboard-tail-methods.js.map +0 -1
- package/dist/multiplexer/dashboard-view-methods.js.map +0 -1
- package/dist/multiplexer/graveyard-view-model.js.map +0 -1
- package/dist/multiplexer/index.js.map +0 -1
- package/dist/multiplexer/navigation.js.map +0 -1
- package/dist/multiplexer/notifications.js.map +0 -1
- package/dist/multiplexer/persistence-methods.js.map +0 -1
- package/dist/multiplexer/runtime-lifecycle-methods.js.map +0 -1
- package/dist/multiplexer/runtime-state.js.map +0 -1
- package/dist/multiplexer/runtime-sync.js.map +0 -1
- package/dist/multiplexer/service-state-snapshot.js.map +0 -1
- package/dist/multiplexer/services.js.map +0 -1
- package/dist/multiplexer/session-actions.d.ts +0 -40
- package/dist/multiplexer/session-actions.js +0 -110
- package/dist/multiplexer/session-actions.js.map +0 -1
- package/dist/multiplexer/session-launch.js.map +0 -1
- package/dist/multiplexer/session-runtime-core.js.map +0 -1
- package/dist/multiplexer/subscreens.js.map +0 -1
- package/dist/multiplexer/tool-picker.js.map +0 -1
- package/dist/multiplexer/worktree-graveyard.js.map +0 -1
- package/dist/multiplexer/worktrees.js.map +0 -1
- package/dist/notification-context.js.map +0 -1
- package/dist/notifications.js.map +0 -1
- package/dist/notify.js.map +0 -1
- package/dist/orchestration-actions.js.map +0 -1
- package/dist/orchestration-dispatcher.d.ts +0 -25
- package/dist/orchestration-dispatcher.js +0 -59
- package/dist/orchestration-dispatcher.js.map +0 -1
- package/dist/orchestration-routing.js.map +0 -1
- package/dist/orchestration.js.map +0 -1
- package/dist/osc-notifications.js.map +0 -1
- package/dist/paths.js.map +0 -1
- package/dist/plugin-runtime.js.map +0 -1
- package/dist/project-events.js.map +0 -1
- package/dist/project-scanner.js.map +0 -1
- package/dist/project-service-manifest.js.map +0 -1
- package/dist/recency.js.map +0 -1
- package/dist/recorder.js.map +0 -1
- package/dist/session-bootstrap.js.map +0 -1
- package/dist/session-input-operations.d.ts +0 -19
- package/dist/session-input-operations.js +0 -46
- package/dist/session-input-operations.js.map +0 -1
- package/dist/session-message-history.d.ts +0 -27
- package/dist/session-message-history.js +0 -105
- package/dist/session-message-history.js.map +0 -1
- package/dist/session-runtime.js.map +0 -1
- package/dist/session-semantics.js.map +0 -1
- package/dist/shell-args.js.map +0 -1
- package/dist/shell-hooks.js.map +0 -1
- package/dist/shell-state.js.map +0 -1
- package/dist/status-detector.js.map +0 -1
- package/dist/statusline-model.js.map +0 -1
- package/dist/task-dispatcher.d.ts +0 -64
- package/dist/task-dispatcher.js +0 -213
- package/dist/task-dispatcher.js.map +0 -1
- package/dist/task-workflow.js.map +0 -1
- package/dist/tasks.js.map +0 -1
- package/dist/team.js.map +0 -1
- package/dist/terminal-host.js.map +0 -1
- package/dist/threads.js.map +0 -1
- package/dist/tmux/doctor.js.map +0 -1
- package/dist/tmux/inbox-popup.js.map +0 -1
- package/dist/tmux/runtime-manager.js.map +0 -1
- package/dist/tmux/session-transport.js.map +0 -1
- package/dist/tmux/statusline-cache.js.map +0 -1
- package/dist/tmux/statusline.js.map +0 -1
- package/dist/tmux/switcher.js.map +0 -1
- package/dist/tmux/window-open.js.map +0 -1
- package/dist/tool-output-watchers.js.map +0 -1
- package/dist/tui/render/box.js.map +0 -1
- package/dist/tui/render/text.js.map +0 -1
- package/dist/tui/screens/dashboard-renderers.js.map +0 -1
- package/dist/tui/screens/overlay-renderers.js.map +0 -1
- package/dist/tui/screens/subscreen-renderers.js.map +0 -1
- package/dist/workflow.js.map +0 -1
- package/dist/worktree.js.map +0 -1
|
@@ -1,31 +1,29 @@
|
|
|
1
|
-
import type { InstanceSessionRef } from "../instance-registry.js";
|
|
2
1
|
import type { SessionRuntime } from "../session-runtime.js";
|
|
3
2
|
import type { Multiplexer, SavedState, ServiceState, SessionState } from "./index.js";
|
|
4
|
-
import { getRemoteInstancesSafe as getRemoteInstancesSafeImpl } from "./runtime-state.js";
|
|
5
3
|
export type RuntimeLifecycleMethods = {
|
|
6
4
|
writeInstructionFiles(this: Multiplexer): void;
|
|
7
5
|
removeInstructionFiles(this: Multiplexer): void;
|
|
8
6
|
startStatusRefresh(this: Multiplexer): void;
|
|
9
7
|
stopStatusRefresh(this: Multiplexer): void;
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
syncSessionsFromTopology(this: Multiplexer): void;
|
|
9
|
+
loadOfflineTopologySessions(this: Multiplexer): boolean;
|
|
12
10
|
loadOfflineServices(this: Multiplexer, state?: SavedState | null): boolean;
|
|
13
11
|
buildLiveServiceStates(this: Multiplexer): ServiceState[];
|
|
14
|
-
|
|
12
|
+
restoreTmuxSessionsFromTopology(this: Multiplexer): void;
|
|
15
13
|
stopSessionToOffline(this: Multiplexer, session: SessionRuntime): void;
|
|
16
14
|
adjustAfterRemove(this: Multiplexer, hasWorktrees: boolean): void;
|
|
17
|
-
graveyardSession(this: Multiplexer, sessionId: string): void;
|
|
15
|
+
graveyardSession(this: Multiplexer, sessionId: string, sessionSeed?: any): void;
|
|
18
16
|
isSessionRuntimeLive(this: Multiplexer, runtime: SessionRuntime): boolean;
|
|
19
17
|
evictZombieSession(this: Multiplexer, runtime: SessionRuntime): void;
|
|
20
18
|
resumeOfflineSession(this: Multiplexer, session: SessionState): void;
|
|
19
|
+
recordSessionBackendSessionId(this: Multiplexer, sessionId: string, backendSessionId: string): {
|
|
20
|
+
sessionId: string;
|
|
21
|
+
backendSessionId: string;
|
|
22
|
+
};
|
|
21
23
|
startHeartbeat(this: Multiplexer): void;
|
|
22
|
-
handleSessionClaimed(this: Multiplexer, sessionId: string): void;
|
|
23
24
|
stopHeartbeat(this: Multiplexer): void;
|
|
24
25
|
startProjectServiceRefresh(this: Multiplexer): void;
|
|
25
26
|
stopProjectServiceRefresh(this: Multiplexer): void;
|
|
26
|
-
getRemoteInstancesSafe(this: Multiplexer): ReturnType<typeof getRemoteInstancesSafeImpl>;
|
|
27
|
-
getRemoteOwnedSessionKeys(this: Multiplexer): Set<string>;
|
|
28
|
-
getInstanceSessionRefs(this: Multiplexer): InstanceSessionRef[];
|
|
29
27
|
saveState(this: Multiplexer): void;
|
|
30
28
|
teardown(this: Multiplexer): void;
|
|
31
29
|
cleanup(this: Multiplexer): void;
|
|
@@ -4,10 +4,55 @@ import { join } from "node:path";
|
|
|
4
4
|
import { closeDebug, debug } from "../debug.js";
|
|
5
5
|
import { loadConfig } from "../config.js";
|
|
6
6
|
import { getStatePath } from "../paths.js";
|
|
7
|
-
import {
|
|
7
|
+
import { buildAimuxAgentInstructions } from "../session-bootstrap.js";
|
|
8
|
+
import { listTopologySessionStates, saveRuntimeTopologySessions } from "../runtime-core/topology-sessions.js";
|
|
9
|
+
import { adjustAfterRemove as adjustAfterRemoveImpl, buildLiveServiceStates as buildLiveServiceStatesImpl, evictZombieSession as evictZombieSessionImpl, graveyardSession as graveyardSessionImpl, isSessionRuntimeLive as isSessionRuntimeLiveImpl, loadOfflineServices as loadOfflineServicesImpl, loadOfflineTopologySessions as loadOfflineTopologySessionsImpl, restoreTmuxSessionsFromTopology as restoreTmuxSessionsFromTopologyImpl, recordSessionBackendSessionId as recordSessionBackendSessionIdImpl, resumeOfflineSession as resumeOfflineSessionImpl, startHeartbeat as startHeartbeatImpl, startProjectServiceRefresh as startProjectServiceRefreshImpl, startStatusRefresh as startStatusRefreshImpl, stopHeartbeat as stopHeartbeatImpl, stopProjectServiceRefresh as stopProjectServiceRefreshImpl, stopSessionToOffline as stopSessionToOfflineImpl, stopStatusRefresh as stopStatusRefreshImpl, syncSessionsFromTopology as syncSessionsFromTopologyImpl, } from "./runtime-state.js";
|
|
10
|
+
const AIMUX_MANAGED_BLOCK_ID = "aimux-agent-instructions";
|
|
11
|
+
const AIMUX_MANAGED_BLOCK_START = `<!-- BEGIN Aimux MANAGED BLOCK: ${AIMUX_MANAGED_BLOCK_ID} -->`;
|
|
12
|
+
const AIMUX_MANAGED_BLOCK_END = `<!-- END Aimux MANAGED BLOCK: ${AIMUX_MANAGED_BLOCK_ID} -->`;
|
|
13
|
+
const LEGACY_DEFAULT_INSTRUCTION_FILES = ["AGENTS.md"];
|
|
14
|
+
function managedInstructionBlock(content) {
|
|
15
|
+
return `${AIMUX_MANAGED_BLOCK_START}\n${content.trim()}\n${AIMUX_MANAGED_BLOCK_END}`;
|
|
16
|
+
}
|
|
17
|
+
function mergeManagedInstructionBlock(existing, content) {
|
|
18
|
+
const block = managedInstructionBlock(content);
|
|
19
|
+
const pattern = new RegExp(`${escapeRegex(AIMUX_MANAGED_BLOCK_START)}[\\s\\S]*?${escapeRegex(AIMUX_MANAGED_BLOCK_END)}`, "m");
|
|
20
|
+
if (pattern.test(existing)) {
|
|
21
|
+
return `${existing.replace(pattern, block).trim()}\n`;
|
|
22
|
+
}
|
|
23
|
+
const prefix = existing.trimEnd();
|
|
24
|
+
return `${prefix ? `${prefix}\n\n` : ""}${block}\n`;
|
|
25
|
+
}
|
|
26
|
+
function stripManagedInstructionBlock(existing) {
|
|
27
|
+
const pattern = new RegExp(`(?:\\n|^)\\s*${escapeRegex(AIMUX_MANAGED_BLOCK_START)}[\\s\\S]*?${escapeRegex(AIMUX_MANAGED_BLOCK_END)}\\s*(?=\\n|$)`, "m");
|
|
28
|
+
return existing
|
|
29
|
+
.replace(pattern, "\n")
|
|
30
|
+
.replace(/\n{3,}/g, "\n\n")
|
|
31
|
+
.trim();
|
|
32
|
+
}
|
|
33
|
+
function cleanupManagedInstructionFile(filePath) {
|
|
34
|
+
if (!existsSync(filePath))
|
|
35
|
+
return;
|
|
36
|
+
const existing = readFileSync(filePath, "utf-8");
|
|
37
|
+
if (!existing.includes(AIMUX_MANAGED_BLOCK_START) || !existing.includes(AIMUX_MANAGED_BLOCK_END))
|
|
38
|
+
return;
|
|
39
|
+
const cleaned = stripManagedInstructionBlock(existing);
|
|
40
|
+
if (cleaned) {
|
|
41
|
+
writeFileSync(filePath, `${cleaned}\n`);
|
|
42
|
+
}
|
|
43
|
+
else {
|
|
44
|
+
unlinkSync(filePath);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
function escapeRegex(value) {
|
|
48
|
+
return value.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
49
|
+
}
|
|
8
50
|
function sanitizeOfflineSessionState(session) {
|
|
9
51
|
const { tmuxTarget: _tmuxTarget, ...rest } = session;
|
|
10
|
-
return {
|
|
52
|
+
return {
|
|
53
|
+
...rest,
|
|
54
|
+
lifecycle: "offline",
|
|
55
|
+
};
|
|
11
56
|
}
|
|
12
57
|
function sessionStateKey(session) {
|
|
13
58
|
return session.backendSessionId ? `backend:${session.backendSessionId}` : `id:${session.id}`;
|
|
@@ -23,22 +68,6 @@ function isRecoverableExistingSession(session) {
|
|
|
23
68
|
return false;
|
|
24
69
|
return Boolean(session.backendSessionId);
|
|
25
70
|
}
|
|
26
|
-
function sessionStateFromInstanceRef(ref) {
|
|
27
|
-
const tool = ref.tool;
|
|
28
|
-
if (!ref.id || !tool)
|
|
29
|
-
return null;
|
|
30
|
-
return {
|
|
31
|
-
id: ref.id,
|
|
32
|
-
tool,
|
|
33
|
-
toolConfigKey: tool,
|
|
34
|
-
command: tool,
|
|
35
|
-
args: [],
|
|
36
|
-
lifecycle: "offline",
|
|
37
|
-
createdAt: ref.createdAt,
|
|
38
|
-
backendSessionId: ref.backendSessionId,
|
|
39
|
-
worktreePath: ref.worktreePath,
|
|
40
|
-
};
|
|
41
|
-
}
|
|
42
71
|
function dedupeSessionStates(sessions) {
|
|
43
72
|
const byKey = new Map();
|
|
44
73
|
for (const session of sessions) {
|
|
@@ -50,12 +79,17 @@ function dedupeSessionStates(sessions) {
|
|
|
50
79
|
}
|
|
51
80
|
export function loadStateStatic() {
|
|
52
81
|
const statePath = getStatePath();
|
|
53
|
-
if (!existsSync(statePath))
|
|
82
|
+
if (!existsSync(statePath)) {
|
|
54
83
|
return null;
|
|
84
|
+
}
|
|
55
85
|
try {
|
|
56
86
|
const raw = readFileSync(statePath, "utf-8");
|
|
57
87
|
const state = JSON.parse(raw);
|
|
58
|
-
return
|
|
88
|
+
return {
|
|
89
|
+
savedAt: typeof state.savedAt === "string" ? state.savedAt : new Date().toISOString(),
|
|
90
|
+
cwd: typeof state.cwd === "string" ? state.cwd : process.cwd(),
|
|
91
|
+
services: Array.isArray(state.services) ? state.services : undefined,
|
|
92
|
+
};
|
|
59
93
|
}
|
|
60
94
|
catch {
|
|
61
95
|
return null;
|
|
@@ -65,16 +99,20 @@ export const runtimeLifecycleMethods = {
|
|
|
65
99
|
writeInstructionFiles() {
|
|
66
100
|
const mux = this;
|
|
67
101
|
const config = loadConfig();
|
|
102
|
+
const configuredInstructionFiles = new Set(Object.values(config.tools)
|
|
103
|
+
.filter((tool) => tool.enabled && tool.instructionsFile)
|
|
104
|
+
.map((tool) => tool.instructionsFile));
|
|
105
|
+
for (const instructionFile of LEGACY_DEFAULT_INSTRUCTION_FILES) {
|
|
106
|
+
if (!configuredInstructionFiles.has(instructionFile)) {
|
|
107
|
+
try {
|
|
108
|
+
cleanupManagedInstructionFile(join(process.cwd(), instructionFile));
|
|
109
|
+
}
|
|
110
|
+
catch { }
|
|
111
|
+
}
|
|
112
|
+
}
|
|
68
113
|
const preamble = "# aimux Agent Instructions\n\n" +
|
|
69
|
-
|
|
70
|
-
"
|
|
71
|
-
"## Context Files\n" +
|
|
72
|
-
"- `.aimux/context/{session-id}/live.md` — each agent's recent conversation\n" +
|
|
73
|
-
"- `.aimux/context/{session-id}/summary.md` — each agent's compacted history\n" +
|
|
74
|
-
"- `.aimux/sessions.json` — all running agents (use to find other agents' session IDs)\n" +
|
|
75
|
-
"- `.aimux/history/` — full raw conversation history (JSONL)\n\n" +
|
|
76
|
-
"Check sessions.json to discover other agents, then read their context files.\n" +
|
|
77
|
-
"This file is auto-generated by aimux and will be removed when aimux exits.\n";
|
|
114
|
+
buildAimuxAgentInstructions() +
|
|
115
|
+
"\n\nThis managed block is written by aimux. User-authored content outside the block is preserved.\n";
|
|
78
116
|
let fullPreamble = preamble;
|
|
79
117
|
for (const mdPath of [join(homedir(), "AIMUX.md"), join(process.cwd(), "AIMUX.md")]) {
|
|
80
118
|
if (existsSync(mdPath)) {
|
|
@@ -92,20 +130,17 @@ export const runtimeLifecycleMethods = {
|
|
|
92
130
|
if (!tool.instructionsFile || !tool.enabled)
|
|
93
131
|
continue;
|
|
94
132
|
const filePath = join(process.cwd(), tool.instructionsFile);
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
continue;
|
|
98
|
-
}
|
|
99
|
-
writeFileSync(filePath, fullPreamble);
|
|
133
|
+
const existing = existsSync(filePath) ? readFileSync(filePath, "utf-8") : "";
|
|
134
|
+
writeFileSync(filePath, mergeManagedInstructionBlock(existing, fullPreamble));
|
|
100
135
|
mux.writtenInstructionFiles.add(filePath);
|
|
101
|
-
debug(`
|
|
136
|
+
debug(`merged aimux managed block into ${tool.instructionsFile}`, "context");
|
|
102
137
|
}
|
|
103
138
|
},
|
|
104
139
|
removeInstructionFiles() {
|
|
105
140
|
const mux = this;
|
|
106
141
|
for (const filePath of mux.writtenInstructionFiles) {
|
|
107
142
|
try {
|
|
108
|
-
|
|
143
|
+
cleanupManagedInstructionFile(filePath);
|
|
109
144
|
}
|
|
110
145
|
catch { }
|
|
111
146
|
}
|
|
@@ -117,11 +152,11 @@ export const runtimeLifecycleMethods = {
|
|
|
117
152
|
stopStatusRefresh() {
|
|
118
153
|
stopStatusRefreshImpl(this);
|
|
119
154
|
},
|
|
120
|
-
|
|
121
|
-
|
|
155
|
+
syncSessionsFromTopology() {
|
|
156
|
+
syncSessionsFromTopologyImpl(this);
|
|
122
157
|
},
|
|
123
|
-
|
|
124
|
-
return
|
|
158
|
+
loadOfflineTopologySessions() {
|
|
159
|
+
return loadOfflineTopologySessionsImpl(this);
|
|
125
160
|
},
|
|
126
161
|
loadOfflineServices(state = loadStateStatic()) {
|
|
127
162
|
return loadOfflineServicesImpl(this, state);
|
|
@@ -129,8 +164,8 @@ export const runtimeLifecycleMethods = {
|
|
|
129
164
|
buildLiveServiceStates() {
|
|
130
165
|
return buildLiveServiceStatesImpl(this);
|
|
131
166
|
},
|
|
132
|
-
|
|
133
|
-
|
|
167
|
+
restoreTmuxSessionsFromTopology() {
|
|
168
|
+
restoreTmuxSessionsFromTopologyImpl(this);
|
|
134
169
|
},
|
|
135
170
|
stopSessionToOffline(session) {
|
|
136
171
|
stopSessionToOfflineImpl(this, session);
|
|
@@ -138,8 +173,8 @@ export const runtimeLifecycleMethods = {
|
|
|
138
173
|
adjustAfterRemove(hasWorktrees) {
|
|
139
174
|
adjustAfterRemoveImpl(this, hasWorktrees);
|
|
140
175
|
},
|
|
141
|
-
graveyardSession(sessionId) {
|
|
142
|
-
graveyardSessionImpl(this, sessionId);
|
|
176
|
+
graveyardSession(sessionId, sessionSeed) {
|
|
177
|
+
graveyardSessionImpl(this, sessionId, sessionSeed);
|
|
143
178
|
},
|
|
144
179
|
isSessionRuntimeLive(runtime) {
|
|
145
180
|
return isSessionRuntimeLiveImpl(this, runtime);
|
|
@@ -150,12 +185,12 @@ export const runtimeLifecycleMethods = {
|
|
|
150
185
|
resumeOfflineSession(session) {
|
|
151
186
|
resumeOfflineSessionImpl(this, session);
|
|
152
187
|
},
|
|
188
|
+
recordSessionBackendSessionId(sessionId, backendSessionId) {
|
|
189
|
+
return recordSessionBackendSessionIdImpl(this, sessionId, backendSessionId);
|
|
190
|
+
},
|
|
153
191
|
startHeartbeat() {
|
|
154
192
|
startHeartbeatImpl(this);
|
|
155
193
|
},
|
|
156
|
-
handleSessionClaimed(sessionId) {
|
|
157
|
-
handleSessionClaimedImpl(this, sessionId);
|
|
158
|
-
},
|
|
159
194
|
stopHeartbeat() {
|
|
160
195
|
stopHeartbeatImpl(this);
|
|
161
196
|
},
|
|
@@ -165,15 +200,6 @@ export const runtimeLifecycleMethods = {
|
|
|
165
200
|
stopProjectServiceRefresh() {
|
|
166
201
|
stopProjectServiceRefreshImpl(this);
|
|
167
202
|
},
|
|
168
|
-
getRemoteInstancesSafe() {
|
|
169
|
-
return getRemoteInstancesSafeImpl(this);
|
|
170
|
-
},
|
|
171
|
-
getRemoteOwnedSessionKeys() {
|
|
172
|
-
return getRemoteOwnedSessionKeysImpl(this);
|
|
173
|
-
},
|
|
174
|
-
getInstanceSessionRefs() {
|
|
175
|
-
return getInstanceSessionRefsImpl(this);
|
|
176
|
-
},
|
|
177
203
|
saveState() {
|
|
178
204
|
const mux = this;
|
|
179
205
|
const liveSessions = mux.sessions
|
|
@@ -188,6 +214,7 @@ export const runtimeLifecycleMethods = {
|
|
|
188
214
|
lifecycle: "live",
|
|
189
215
|
createdAt: s.startTime ? new Date(s.startTime).toISOString() : undefined,
|
|
190
216
|
backendSessionId: s.backendSessionId,
|
|
217
|
+
team: s.team,
|
|
191
218
|
worktreePath: mux.sessionWorktreePaths.get(s.id),
|
|
192
219
|
label: this.getSessionLabel(s.id),
|
|
193
220
|
headline: this.deriveHeadline(s.id),
|
|
@@ -195,41 +222,35 @@ export const runtimeLifecycleMethods = {
|
|
|
195
222
|
}));
|
|
196
223
|
const liveKeys = new Set(liveSessions.map(sessionStateKey));
|
|
197
224
|
const offlineSessions = mux.offlineSessions
|
|
198
|
-
.map(sanitizeOfflineSessionState)
|
|
225
|
+
.map((session) => sanitizeOfflineSessionState(session))
|
|
199
226
|
.filter((session) => !liveKeys.has(sessionStateKey(session)));
|
|
200
227
|
const mySessions = dedupeSessionStates([...liveSessions, ...offlineSessions]);
|
|
201
|
-
const remoteRefs = this.getRemoteInstancesSafe().flatMap((instance) => instance.sessions);
|
|
202
|
-
const remoteSessions = dedupeSessionStates(remoteRefs.flatMap((ref) => {
|
|
203
|
-
const session = sessionStateFromInstanceRef(ref);
|
|
204
|
-
return session ? [session] : [];
|
|
205
|
-
}));
|
|
206
228
|
const removedServiceIds = mux.removedServiceIds ?? new Set();
|
|
207
229
|
const liveServices = this.buildLiveServiceStates().filter((service) => !removedServiceIds.has(service.id));
|
|
208
230
|
const myServices = [...mux.offlineServices, ...liveServices].filter((service, index, services) => services.findIndex((entry) => entry.id === service.id) === index);
|
|
209
231
|
const statePath = getStatePath();
|
|
210
|
-
|
|
232
|
+
const myBackendIds = new Set(mySessions.map((s) => s.backendSessionId).filter(Boolean));
|
|
233
|
+
const myIds = new Set(mySessions.map((s) => s.id));
|
|
234
|
+
const unpreservedExitedIds = mux.unpreservedExitedSessionIds ?? new Set();
|
|
235
|
+
const topologySessions = listTopologySessionStates({
|
|
236
|
+
statuses: ["running", "idle", "offline"],
|
|
237
|
+
});
|
|
238
|
+
const otherSessions = topologySessions.flatMap((s) => {
|
|
239
|
+
if (unpreservedExitedIds.has(s.id))
|
|
240
|
+
return [];
|
|
241
|
+
if (s.backendSessionId && myBackendIds.has(s.backendSessionId))
|
|
242
|
+
return [];
|
|
243
|
+
if (myIds.has(s.id))
|
|
244
|
+
return [];
|
|
245
|
+
if (!isRecoverableExistingSession(s))
|
|
246
|
+
return [];
|
|
247
|
+
return [s];
|
|
248
|
+
});
|
|
249
|
+
const mergedSessions = dedupeSessionStates([...otherSessions, ...mySessions]);
|
|
211
250
|
let mergedServices = myServices;
|
|
212
251
|
if (existsSync(statePath)) {
|
|
213
252
|
try {
|
|
214
253
|
const existing = JSON.parse(readFileSync(statePath, "utf-8"));
|
|
215
|
-
const remoteIds = new Set(remoteRefs.map((s) => s.id));
|
|
216
|
-
const remoteBackendIds = new Set(remoteRefs.map((s) => s.backendSessionId).filter(Boolean));
|
|
217
|
-
const myBackendIds = new Set(mySessions.map((s) => s.backendSessionId).filter(Boolean));
|
|
218
|
-
const myIds = new Set(mySessions.map((s) => s.id));
|
|
219
|
-
const otherSessions = existing.sessions.flatMap((s) => {
|
|
220
|
-
if (remoteIds.has(s.id))
|
|
221
|
-
return [s];
|
|
222
|
-
if (s.backendSessionId && remoteBackendIds.has(s.backendSessionId))
|
|
223
|
-
return [s];
|
|
224
|
-
if (s.backendSessionId && myBackendIds.has(s.backendSessionId))
|
|
225
|
-
return [];
|
|
226
|
-
if (myIds.has(s.id))
|
|
227
|
-
return [];
|
|
228
|
-
if (!isRecoverableExistingSession(s))
|
|
229
|
-
return [];
|
|
230
|
-
return [sanitizeOfflineSessionState(s)];
|
|
231
|
-
});
|
|
232
|
-
mergedSessions = dedupeSessionStates([...remoteSessions, ...otherSessions, ...mySessions]);
|
|
233
254
|
const myServiceIds = new Set(myServices.map((service) => service.id));
|
|
234
255
|
const otherServices = (existing.services ?? []).filter((service) => {
|
|
235
256
|
if (removedServiceIds.has(service.id))
|
|
@@ -242,10 +263,11 @@ export const runtimeLifecycleMethods = {
|
|
|
242
263
|
}
|
|
243
264
|
catch { }
|
|
244
265
|
}
|
|
266
|
+
saveRuntimeTopologySessions({ sessions: mergedSessions });
|
|
267
|
+
unpreservedExitedIds.clear();
|
|
245
268
|
const state = {
|
|
246
269
|
savedAt: new Date().toISOString(),
|
|
247
270
|
cwd: process.cwd(),
|
|
248
|
-
sessions: mergedSessions,
|
|
249
271
|
services: mergedServices,
|
|
250
272
|
};
|
|
251
273
|
writeFileSync(statePath, JSON.stringify(state, null, 2) + "\n");
|
|
@@ -257,13 +279,9 @@ export const runtimeLifecycleMethods = {
|
|
|
257
279
|
this.clearDashboardBusy();
|
|
258
280
|
this.stopHeartbeat();
|
|
259
281
|
this.stopProjectServiceRefresh();
|
|
260
|
-
mux.taskDispatcher = null;
|
|
261
|
-
mux.orchestrationDispatcher = null;
|
|
262
|
-
mux.instanceDirectory.unregisterInstance(mux.instanceId, process.cwd()).catch(() => { });
|
|
263
282
|
this.saveState();
|
|
264
283
|
this.stopStatusRefresh();
|
|
265
284
|
mux.contextWatcher.stop();
|
|
266
|
-
this.removeSessionsFile();
|
|
267
285
|
this.removeInstructionFiles();
|
|
268
286
|
closeDebug();
|
|
269
287
|
if (mux.onStdinData) {
|
|
@@ -306,4 +324,3 @@ export const runtimeLifecycleMethods = {
|
|
|
306
324
|
process.exit(0);
|
|
307
325
|
},
|
|
308
326
|
};
|
|
309
|
-
//# sourceMappingURL=runtime-lifecycle-methods.js.map
|
|
@@ -6,27 +6,25 @@ type ManagedAgentWindow = {
|
|
|
6
6
|
export declare function renderCurrentDashboardView(host: RuntimeStateHost): void;
|
|
7
7
|
export declare function startStatusRefresh(host: RuntimeStateHost): void;
|
|
8
8
|
export declare function stopStatusRefresh(host: RuntimeStateHost): void;
|
|
9
|
-
export declare function
|
|
10
|
-
export declare function
|
|
9
|
+
export declare function syncSessionsFromTopology(host: RuntimeStateHost): void;
|
|
10
|
+
export declare function loadOfflineTopologySessions(host: RuntimeStateHost, liveAgentWindows?: ManagedAgentWindow[]): boolean;
|
|
11
11
|
export declare function loadOfflineServices(host: RuntimeStateHost, state?: any): boolean;
|
|
12
12
|
export declare function buildLiveServiceStates(host: RuntimeStateHost): any[];
|
|
13
|
-
export declare function
|
|
13
|
+
export declare function restoreTmuxSessionsFromTopology(host: RuntimeStateHost): ManagedAgentWindow[];
|
|
14
14
|
export declare function stopSessionToOffline(host: RuntimeStateHost, session: any): void;
|
|
15
15
|
export declare function adjustAfterRemove(host: RuntimeStateHost, hasWorktrees: boolean): void;
|
|
16
|
-
export declare function graveyardSession(host: RuntimeStateHost, sessionId: string): void;
|
|
16
|
+
export declare function graveyardSession(host: RuntimeStateHost, sessionId: string, _sessionSeed?: any): void;
|
|
17
17
|
export declare function isSessionRuntimeLive(host: RuntimeStateHost, runtime: any): boolean;
|
|
18
18
|
export declare function evictZombieSession(host: RuntimeStateHost, runtime: any): void;
|
|
19
19
|
export declare function resumeOfflineSession(host: RuntimeStateHost, session: any): void;
|
|
20
|
+
export declare function recordSessionBackendSessionId(host: RuntimeStateHost, sessionId: string, backendSessionId: string): {
|
|
21
|
+
sessionId: string;
|
|
22
|
+
backendSessionId: string;
|
|
23
|
+
};
|
|
20
24
|
export declare function startHeartbeat(host: RuntimeStateHost): void;
|
|
21
|
-
export declare function handleSessionClaimed(host: RuntimeStateHost, sessionId: string): void;
|
|
22
25
|
export declare function stopHeartbeat(host: RuntimeStateHost): void;
|
|
23
26
|
export declare function startProjectServiceRefresh(host: RuntimeStateHost): void;
|
|
24
27
|
export declare function stopProjectServiceRefresh(host: RuntimeStateHost): void;
|
|
25
|
-
export declare function getRemoteInstancesSafe(host: RuntimeStateHost): any;
|
|
26
|
-
export declare function getRemoteOwnedSessionKeys(host: RuntimeStateHost): Set<string>;
|
|
27
|
-
export declare function getInstanceSessionRefs(host: RuntimeStateHost): any[];
|
|
28
|
-
export declare function writeSessionsFile(host: RuntimeStateHost): void;
|
|
29
|
-
export declare function removeSessionsFile(): void;
|
|
30
28
|
export declare function listDesktopWorktrees(_host: RuntimeStateHost): Array<{
|
|
31
29
|
name: string;
|
|
32
30
|
path: string;
|