very-happy-cli 0.2.115 → 0.2.116
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/{AcpBackend-BrZN8KM-.cjs → AcpBackend-CauAQpC1.cjs} +1 -1
- package/dist/{AcpBackend-DEZTWZZu.mjs → AcpBackend-CfKPvoTU.mjs} +1 -1
- package/dist/{AcpSessionManager-BzP3eiOG.mjs → AcpSessionManager-BQ6pBRW4.mjs} +1 -1
- package/dist/{AcpSessionManager-DjulpKY0.cjs → AcpSessionManager-CA6xeET_.cjs} +1 -1
- package/dist/{config-BNAsx9Wg.cjs → config-BoteFn-v.cjs} +2 -2
- package/dist/{config-CMgRBQMS.mjs → config-BpR_CwZu.mjs} +2 -2
- package/dist/{index-tPXwlc_t.cjs → index-4jiUeiUz.cjs} +110 -18
- package/dist/{index-CpGR7rIw.mjs → index-C45xN8s0.mjs} +5 -5
- package/dist/{index-B2KfhNku.mjs → index-D7azxfcs.mjs} +2 -2
- package/dist/{index-ClR0jhjm.cjs → index-DWmhmji9.cjs} +4 -4
- package/dist/{index-BHNEb4bc.mjs → index-Dq-eFp89.mjs} +106 -14
- package/dist/{index-B3UkbonP.cjs → index-lX1UliOs.cjs} +2 -2
- package/dist/index.cjs +2 -2
- package/dist/index.mjs +2 -2
- package/dist/{installTerminalHooks-CWfCF68p.cjs → installTerminalHooks-DnaFkrTF.cjs} +2 -2
- package/dist/{installTerminalHooks-DD6QuHfT.mjs → installTerminalHooks-k3TrBHD0.mjs} +2 -2
- package/dist/lib.cjs +1 -1
- package/dist/lib.d.cts +25 -0
- package/dist/lib.d.mts +25 -0
- package/dist/lib.mjs +1 -1
- package/dist/{mcp-CiNrjYox.mjs → mcp-DRePTOap.mjs} +2 -2
- package/dist/{mcp-CqjiDRnG.cjs → mcp-DSpEpM_2.cjs} +2 -2
- package/dist/{runGemini-UN5IznJp.cjs → runGemini-IWHyBq0A.cjs} +4 -4
- package/dist/{runGemini-DdJqpywr.mjs → runGemini-_9-a7duU.mjs} +4 -4
- package/dist/{runOpenClaw-9hhfGllZ.cjs → runOpenClaw-0myYIz1U.cjs} +3 -3
- package/dist/{runOpenClaw-CM5UrVBy.mjs → runOpenClaw-Boq6LQ9a.mjs} +3 -3
- package/dist/{send-CnVtXOj0.cjs → send-CwWvFfay.cjs} +2 -2
- package/dist/{send-C6G2jsQp.mjs → send-Cyo6mgMl.mjs} +2 -2
- package/dist/{sessions-CGdcF05T.cjs → sessions-CbzqYiAy.cjs} +2 -2
- package/dist/{sessions-CmabJzYS.mjs → sessions-lvfTH_ql.mjs} +2 -2
- package/dist/{spawn-qb344Y5E.mjs → spawn-CU0DMauA.mjs} +2 -2
- package/dist/{spawn-CfYddkS_.cjs → spawn-DQ6FTUK9.cjs} +2 -2
- package/dist/{types-CpnzfHHS.cjs → types-C5kEpkcZ.cjs} +150 -15
- package/dist/{types-B3qx8Ga1.mjs → types-Ds0SiQ1D.mjs} +149 -14
- package/package.json +7 -7
|
@@ -5,8 +5,8 @@ var path = require('node:path');
|
|
|
5
5
|
var os = require('node:os');
|
|
6
6
|
var node_child_process = require('node:child_process');
|
|
7
7
|
var chalk = require('chalk');
|
|
8
|
-
var persistence = require('./types-
|
|
9
|
-
var index = require('./index-
|
|
8
|
+
var persistence = require('./types-C5kEpkcZ.cjs');
|
|
9
|
+
var index = require('./index-4jiUeiUz.cjs');
|
|
10
10
|
require('axios');
|
|
11
11
|
require('node:util');
|
|
12
12
|
require('node:fs/promises');
|
|
@@ -3,8 +3,8 @@ import { join, resolve } from 'node:path';
|
|
|
3
3
|
import { homedir } from 'node:os';
|
|
4
4
|
import { spawnSync } from 'node:child_process';
|
|
5
5
|
import chalk from 'chalk';
|
|
6
|
-
import { p as projectPath } from './types-
|
|
7
|
-
import { t as tmuxSupportsSessionEnv } from './index-
|
|
6
|
+
import { p as projectPath } from './types-Ds0SiQ1D.mjs';
|
|
7
|
+
import { t as tmuxSupportsSessionEnv } from './index-Dq-eFp89.mjs';
|
|
8
8
|
import 'axios';
|
|
9
9
|
import 'node:util';
|
|
10
10
|
import 'node:fs/promises';
|
package/dist/lib.cjs
CHANGED
package/dist/lib.d.cts
CHANGED
|
@@ -340,6 +340,17 @@ declare const CliUpdateStateSchema: z$1.ZodObject<{
|
|
|
340
340
|
reason: z$1.ZodString;
|
|
341
341
|
at: z$1.ZodNumber;
|
|
342
342
|
}, z$1.core.$strip>>>;
|
|
343
|
+
autoUpdate: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodObject<{
|
|
344
|
+
state: z$1.ZodUnion<readonly [z$1.ZodEnum<{
|
|
345
|
+
installing: "installing";
|
|
346
|
+
installed: "installed";
|
|
347
|
+
failed: "failed";
|
|
348
|
+
skipped: "skipped";
|
|
349
|
+
}>, z$1.ZodString]>;
|
|
350
|
+
version: z$1.ZodNullable<z$1.ZodString>;
|
|
351
|
+
detail: z$1.ZodOptional<z$1.ZodString>;
|
|
352
|
+
at: z$1.ZodNumber;
|
|
353
|
+
}, z$1.core.$strip>>>;
|
|
343
354
|
}, z$1.core.$strip>;
|
|
344
355
|
type CliUpdateState = z$1.infer<typeof CliUpdateStateSchema>;
|
|
345
356
|
/**
|
|
@@ -423,6 +434,17 @@ declare const DaemonStateSchema: z$1.ZodObject<{
|
|
|
423
434
|
reason: z$1.ZodString;
|
|
424
435
|
at: z$1.ZodNumber;
|
|
425
436
|
}, z$1.core.$strip>>>;
|
|
437
|
+
autoUpdate: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodObject<{
|
|
438
|
+
state: z$1.ZodUnion<readonly [z$1.ZodEnum<{
|
|
439
|
+
installing: "installing";
|
|
440
|
+
installed: "installed";
|
|
441
|
+
failed: "failed";
|
|
442
|
+
skipped: "skipped";
|
|
443
|
+
}>, z$1.ZodString]>;
|
|
444
|
+
version: z$1.ZodNullable<z$1.ZodString>;
|
|
445
|
+
detail: z$1.ZodOptional<z$1.ZodString>;
|
|
446
|
+
at: z$1.ZodNumber;
|
|
447
|
+
}, z$1.core.$strip>>>;
|
|
426
448
|
}, z$1.core.$strip>>;
|
|
427
449
|
claudeAuth: z$1.ZodOptional<z$1.ZodObject<{
|
|
428
450
|
probeVersion: z$1.ZodNumber;
|
|
@@ -1255,6 +1277,9 @@ declare class ApiMachineClient {
|
|
|
1255
1277
|
private reconnectInterval;
|
|
1256
1278
|
private handoverInFlight;
|
|
1257
1279
|
private encTerminals;
|
|
1280
|
+
/** B-327: an auto-update swaps the process that owns these terminals, so it
|
|
1281
|
+
* waits until there are none. */
|
|
1282
|
+
hasLiveTerminals(): boolean;
|
|
1258
1283
|
private webTerminal;
|
|
1259
1284
|
/**
|
|
1260
1285
|
* Push text to the clipboard of every web client the user has open
|
package/dist/lib.d.mts
CHANGED
|
@@ -340,6 +340,17 @@ declare const CliUpdateStateSchema: z$1.ZodObject<{
|
|
|
340
340
|
reason: z$1.ZodString;
|
|
341
341
|
at: z$1.ZodNumber;
|
|
342
342
|
}, z$1.core.$strip>>>;
|
|
343
|
+
autoUpdate: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodObject<{
|
|
344
|
+
state: z$1.ZodUnion<readonly [z$1.ZodEnum<{
|
|
345
|
+
installing: "installing";
|
|
346
|
+
installed: "installed";
|
|
347
|
+
failed: "failed";
|
|
348
|
+
skipped: "skipped";
|
|
349
|
+
}>, z$1.ZodString]>;
|
|
350
|
+
version: z$1.ZodNullable<z$1.ZodString>;
|
|
351
|
+
detail: z$1.ZodOptional<z$1.ZodString>;
|
|
352
|
+
at: z$1.ZodNumber;
|
|
353
|
+
}, z$1.core.$strip>>>;
|
|
343
354
|
}, z$1.core.$strip>;
|
|
344
355
|
type CliUpdateState = z$1.infer<typeof CliUpdateStateSchema>;
|
|
345
356
|
/**
|
|
@@ -423,6 +434,17 @@ declare const DaemonStateSchema: z$1.ZodObject<{
|
|
|
423
434
|
reason: z$1.ZodString;
|
|
424
435
|
at: z$1.ZodNumber;
|
|
425
436
|
}, z$1.core.$strip>>>;
|
|
437
|
+
autoUpdate: z$1.ZodOptional<z$1.ZodNullable<z$1.ZodObject<{
|
|
438
|
+
state: z$1.ZodUnion<readonly [z$1.ZodEnum<{
|
|
439
|
+
installing: "installing";
|
|
440
|
+
installed: "installed";
|
|
441
|
+
failed: "failed";
|
|
442
|
+
skipped: "skipped";
|
|
443
|
+
}>, z$1.ZodString]>;
|
|
444
|
+
version: z$1.ZodNullable<z$1.ZodString>;
|
|
445
|
+
detail: z$1.ZodOptional<z$1.ZodString>;
|
|
446
|
+
at: z$1.ZodNumber;
|
|
447
|
+
}, z$1.core.$strip>>>;
|
|
426
448
|
}, z$1.core.$strip>>;
|
|
427
449
|
claudeAuth: z$1.ZodOptional<z$1.ZodObject<{
|
|
428
450
|
probeVersion: z$1.ZodNumber;
|
|
@@ -1255,6 +1277,9 @@ declare class ApiMachineClient {
|
|
|
1255
1277
|
private reconnectInterval;
|
|
1256
1278
|
private handoverInFlight;
|
|
1257
1279
|
private encTerminals;
|
|
1280
|
+
/** B-327: an auto-update swaps the process that owns these terminals, so it
|
|
1281
|
+
* waits until there are none. */
|
|
1282
|
+
hasLiveTerminals(): boolean;
|
|
1258
1283
|
private webTerminal;
|
|
1259
1284
|
/**
|
|
1260
1285
|
* Push text to the clipboard of every web client the user has open
|
package/dist/lib.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as ApiClient, a as ApiSessionClient, R as RawJSONLinesSchema, c as configuration, l as logger } from './types-
|
|
1
|
+
export { A as ApiClient, a as ApiSessionClient, R as RawJSONLinesSchema, c as configuration, l as logger } from './types-Ds0SiQ1D.mjs';
|
|
2
2
|
import 'axios';
|
|
3
3
|
import 'chalk';
|
|
4
4
|
import 'node:util';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
|
|
2
2
|
import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
|
|
3
3
|
import { z } from 'zod';
|
|
4
|
-
import { p as pushClipboardViaDaemon } from './index-
|
|
4
|
+
import { p as pushClipboardViaDaemon } from './index-Dq-eFp89.mjs';
|
|
5
5
|
import { C as CLIPBOARD_TOOL_NAME, a as CLIPBOARD_TOOL_TITLE, b as CLIPBOARD_TOOL_DESCRIPTION, c as CLIPBOARD_MAX_BYTES } from './limits-CwFb5S2b.mjs';
|
|
6
|
-
import { l as logger } from './types-
|
|
6
|
+
import { l as logger } from './types-Ds0SiQ1D.mjs';
|
|
7
7
|
import 'chalk';
|
|
8
8
|
import 'node:os';
|
|
9
9
|
import 'node:crypto';
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
var mcp_js = require('@modelcontextprotocol/sdk/server/mcp.js');
|
|
4
4
|
var stdio_js = require('@modelcontextprotocol/sdk/server/stdio.js');
|
|
5
5
|
var z = require('zod');
|
|
6
|
-
var index = require('./index-
|
|
6
|
+
var index = require('./index-4jiUeiUz.cjs');
|
|
7
7
|
var limits = require('./limits-KdWKmwtH.cjs');
|
|
8
|
-
var persistence = require('./types-
|
|
8
|
+
var persistence = require('./types-C5kEpkcZ.cjs');
|
|
9
9
|
require('chalk');
|
|
10
10
|
require('node:os');
|
|
11
11
|
require('node:crypto');
|
|
@@ -4,10 +4,10 @@ var ink = require('ink');
|
|
|
4
4
|
var React = require('react');
|
|
5
5
|
var node_crypto = require('node:crypto');
|
|
6
6
|
var path = require('node:path');
|
|
7
|
-
var persistence = require('./types-
|
|
8
|
-
var index = require('./index-
|
|
9
|
-
var AcpBackend = require('./AcpBackend-
|
|
10
|
-
var config = require('./config-
|
|
7
|
+
var persistence = require('./types-C5kEpkcZ.cjs');
|
|
8
|
+
var index = require('./index-4jiUeiUz.cjs');
|
|
9
|
+
var AcpBackend = require('./AcpBackend-CauAQpC1.cjs');
|
|
10
|
+
var config = require('./config-BoteFn-v.cjs');
|
|
11
11
|
require('axios');
|
|
12
12
|
require('chalk');
|
|
13
13
|
require('node:util');
|
|
@@ -2,10 +2,10 @@ import { useStdout, useInput, Box, Text, render } from 'ink';
|
|
|
2
2
|
import React, { useState, useRef, useEffect, useCallback } from 'react';
|
|
3
3
|
import { randomUUID } from 'node:crypto';
|
|
4
4
|
import { join } from 'node:path';
|
|
5
|
-
import { l as logger, h as connectionState, A as ApiClient, j as readSettings, e as errorLogMetadata, k as encodeBase64, p as projectPath, d as contentLogMetadata } from './types-
|
|
6
|
-
import { x as GEMINI_API_KEY_ENV, y as GOOGLE_API_KEY_ENV, G as GEMINI_MODEL_ENV, B as BasePermissionHandler, z as BaseReasoningProcessor, h as initialMachineMetadata, j as createSessionMetadata, k as setupOfflineReconnection, n as notifyDaemonSessionStarted, m as MessageQueue2, o as hashObject, C as MessageBuffer, E as CHANGE_TITLE_INSTRUCTION, v as registerKillSessionHandler, u as startHappyServer } from './index-
|
|
7
|
-
import { A as AcpBackend } from './AcpBackend-
|
|
8
|
-
import { readGeminiLocalConfig, determineGeminiModel, getGeminiModelSource, getInitialGeminiModel, saveGeminiModelToConfig } from './config-
|
|
5
|
+
import { l as logger, h as connectionState, A as ApiClient, j as readSettings, e as errorLogMetadata, k as encodeBase64, p as projectPath, d as contentLogMetadata } from './types-Ds0SiQ1D.mjs';
|
|
6
|
+
import { x as GEMINI_API_KEY_ENV, y as GOOGLE_API_KEY_ENV, G as GEMINI_MODEL_ENV, B as BasePermissionHandler, z as BaseReasoningProcessor, h as initialMachineMetadata, j as createSessionMetadata, k as setupOfflineReconnection, n as notifyDaemonSessionStarted, m as MessageQueue2, o as hashObject, C as MessageBuffer, E as CHANGE_TITLE_INSTRUCTION, v as registerKillSessionHandler, u as startHappyServer } from './index-Dq-eFp89.mjs';
|
|
7
|
+
import { A as AcpBackend } from './AcpBackend-CfKPvoTU.mjs';
|
|
8
|
+
import { readGeminiLocalConfig, determineGeminiModel, getGeminiModelSource, getInitialGeminiModel, saveGeminiModelToConfig } from './config-BpR_CwZu.mjs';
|
|
9
9
|
import 'axios';
|
|
10
10
|
import 'chalk';
|
|
11
11
|
import 'node:util';
|
|
@@ -5,9 +5,9 @@ var node_child_process = require('node:child_process');
|
|
|
5
5
|
var os = require('node:os');
|
|
6
6
|
var node_fs = require('node:fs');
|
|
7
7
|
var path = require('node:path');
|
|
8
|
-
var persistence = require('./types-
|
|
9
|
-
var AcpSessionManager = require('./AcpSessionManager-
|
|
10
|
-
var index = require('./index-
|
|
8
|
+
var persistence = require('./types-C5kEpkcZ.cjs');
|
|
9
|
+
var AcpSessionManager = require('./AcpSessionManager-CA6xeET_.cjs');
|
|
10
|
+
var index = require('./index-4jiUeiUz.cjs');
|
|
11
11
|
var WebSocket = require('ws');
|
|
12
12
|
var ed = require('@noble/ed25519');
|
|
13
13
|
var sha2_js = require('@noble/hashes/sha2.js');
|
|
@@ -3,9 +3,9 @@ import { execFileSync } from 'node:child_process';
|
|
|
3
3
|
import os from 'node:os';
|
|
4
4
|
import { existsSync, readFileSync } from 'node:fs';
|
|
5
5
|
import { join } from 'node:path';
|
|
6
|
-
import { m as ensurePrivateDirectorySync, n as hardenPrivateFileSync, w as writePrivateFileSync, e as errorLogMetadata, d as contentLogMetadata, h as connectionState, A as ApiClient, j as readSettings, k as encodeBase64, l as logger, c as configuration } from './types-
|
|
7
|
-
import { A as AcpSessionManager } from './AcpSessionManager-
|
|
8
|
-
import { h as initialMachineMetadata, j as createSessionMetadata, k as setupOfflineReconnection, n as notifyDaemonSessionStarted, m as MessageQueue2, v as registerKillSessionHandler } from './index-
|
|
6
|
+
import { m as ensurePrivateDirectorySync, n as hardenPrivateFileSync, w as writePrivateFileSync, e as errorLogMetadata, d as contentLogMetadata, h as connectionState, A as ApiClient, j as readSettings, k as encodeBase64, l as logger, c as configuration } from './types-Ds0SiQ1D.mjs';
|
|
7
|
+
import { A as AcpSessionManager } from './AcpSessionManager-BQ6pBRW4.mjs';
|
|
8
|
+
import { h as initialMachineMetadata, j as createSessionMetadata, k as setupOfflineReconnection, n as notifyDaemonSessionStarted, m as MessageQueue2, v as registerKillSessionHandler } from './index-Dq-eFp89.mjs';
|
|
9
9
|
import WebSocket from 'ws';
|
|
10
10
|
import * as ed from '@noble/ed25519';
|
|
11
11
|
import { sha512 } from '@noble/hashes/sha2.js';
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
var chalk = require('chalk');
|
|
4
4
|
var node_fs = require('node:fs');
|
|
5
5
|
var path = require('node:path');
|
|
6
|
-
var persistence = require('./types-
|
|
7
|
-
var index = require('./index-
|
|
6
|
+
var persistence = require('./types-C5kEpkcZ.cjs');
|
|
7
|
+
var index = require('./index-4jiUeiUz.cjs');
|
|
8
8
|
require('axios');
|
|
9
9
|
require('node:util');
|
|
10
10
|
require('node:os');
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import chalk from 'chalk';
|
|
2
2
|
import { readFileSync } from 'node:fs';
|
|
3
3
|
import { resolve } from 'node:path';
|
|
4
|
-
import { r as readPersistedSessions, c as configuration } from './types-
|
|
5
|
-
import { d as sendUserMessage, a as sessionWebUrl } from './index-
|
|
4
|
+
import { r as readPersistedSessions, c as configuration } from './types-Ds0SiQ1D.mjs';
|
|
5
|
+
import { d as sendUserMessage, a as sessionWebUrl } from './index-Dq-eFp89.mjs';
|
|
6
6
|
import 'axios';
|
|
7
7
|
import 'node:util';
|
|
8
8
|
import 'node:os';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chalk = require('chalk');
|
|
4
|
-
var index = require('./index-
|
|
5
|
-
var persistence = require('./types-
|
|
4
|
+
var index = require('./index-4jiUeiUz.cjs');
|
|
5
|
+
var persistence = require('./types-C5kEpkcZ.cjs');
|
|
6
6
|
require('node:os');
|
|
7
7
|
require('node:crypto');
|
|
8
8
|
require('cross-spawn');
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import chalk from 'chalk';
|
|
2
|
-
import { D as DEFAULT_RECENT_LIMIT, M as MAX_READ_LIMIT, l as listSessions, r as readSessionTranscript, e as stopSession, f as archiveSession } from './index-
|
|
3
|
-
import { i as isValidSessionId } from './types-
|
|
2
|
+
import { D as DEFAULT_RECENT_LIMIT, M as MAX_READ_LIMIT, l as listSessions, r as readSessionTranscript, e as stopSession, f as archiveSession } from './index-Dq-eFp89.mjs';
|
|
3
|
+
import { i as isValidSessionId } from './types-Ds0SiQ1D.mjs';
|
|
4
4
|
import 'node:os';
|
|
5
5
|
import 'node:crypto';
|
|
6
6
|
import 'cross-spawn';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import chalk from 'chalk';
|
|
2
2
|
import { readFileSync, statSync } from 'node:fs';
|
|
3
3
|
import { resolve } from 'node:path';
|
|
4
|
-
import { c as checkIfDaemonRunningAndCleanupStaleState, s as spawnDaemonSession, a as sessionWebUrl, i as isValidSpawnOrigin, b as sanitizeSpawnPermissionMode, A as ALLOWED_SPAWN_PERMISSION_MODES, w as waitForSessionKey, d as sendUserMessage } from './index-
|
|
5
|
-
import { l as logger } from './types-
|
|
4
|
+
import { c as checkIfDaemonRunningAndCleanupStaleState, s as spawnDaemonSession, a as sessionWebUrl, i as isValidSpawnOrigin, b as sanitizeSpawnPermissionMode, A as ALLOWED_SPAWN_PERMISSION_MODES, w as waitForSessionKey, d as sendUserMessage } from './index-Dq-eFp89.mjs';
|
|
5
|
+
import { l as logger } from './types-Ds0SiQ1D.mjs';
|
|
6
6
|
import 'node:os';
|
|
7
7
|
import 'node:crypto';
|
|
8
8
|
import 'cross-spawn';
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
var chalk = require('chalk');
|
|
4
4
|
var node_fs = require('node:fs');
|
|
5
5
|
var path = require('node:path');
|
|
6
|
-
var index = require('./index-
|
|
7
|
-
var persistence = require('./types-
|
|
6
|
+
var index = require('./index-4jiUeiUz.cjs');
|
|
7
|
+
var persistence = require('./types-C5kEpkcZ.cjs');
|
|
8
8
|
require('node:os');
|
|
9
9
|
require('node:crypto');
|
|
10
10
|
require('cross-spawn');
|
|
@@ -51,7 +51,7 @@ var z__namespace = /*#__PURE__*/_interopNamespaceDefault(z);
|
|
|
51
51
|
var pty__namespace = /*#__PURE__*/_interopNamespaceDefault(pty);
|
|
52
52
|
|
|
53
53
|
var name = "very-happy-cli";
|
|
54
|
-
var version = "0.2.
|
|
54
|
+
var version = "0.2.116";
|
|
55
55
|
var description = "Remote multi-agent workspace CLI with deep Claude integration, native terminal streaming, and self-hosting.";
|
|
56
56
|
var author = "Kirill Dubovitskiy";
|
|
57
57
|
var contributors = [
|
|
@@ -164,12 +164,12 @@ var dependencies = {
|
|
|
164
164
|
zod: "^4.0.0"
|
|
165
165
|
};
|
|
166
166
|
var optionalDependencies = {
|
|
167
|
-
"very-happy-tools-arm64-darwin": "0.2.
|
|
168
|
-
"very-happy-tools-x64-darwin": "0.2.
|
|
169
|
-
"very-happy-tools-arm64-linux": "0.2.
|
|
170
|
-
"very-happy-tools-x64-linux": "0.2.
|
|
171
|
-
"very-happy-tools-arm64-win32": "0.2.
|
|
172
|
-
"very-happy-tools-x64-win32": "0.2.
|
|
167
|
+
"very-happy-tools-arm64-darwin": "0.2.116",
|
|
168
|
+
"very-happy-tools-x64-darwin": "0.2.116",
|
|
169
|
+
"very-happy-tools-arm64-linux": "0.2.116",
|
|
170
|
+
"very-happy-tools-x64-linux": "0.2.116",
|
|
171
|
+
"very-happy-tools-arm64-win32": "0.2.116",
|
|
172
|
+
"very-happy-tools-x64-win32": "0.2.116"
|
|
173
173
|
};
|
|
174
174
|
var devDependencies = {
|
|
175
175
|
"@slopus/happy-wire": "workspace:*",
|
|
@@ -1076,7 +1076,14 @@ const CliUpdateStateSchema = z.z.object({
|
|
|
1076
1076
|
* serving the old code. Present only while that is true. Optional and additive:
|
|
1077
1077
|
* old web builds ignore it, old daemons never send it (iron rule 4).
|
|
1078
1078
|
*/
|
|
1079
|
-
handoverHold: z.z.object({ reason: z.z.string(), at: z.z.number() }).nullable().optional()
|
|
1079
|
+
handoverHold: z.z.object({ reason: z.z.string(), at: z.z.number() }).nullable().optional(),
|
|
1080
|
+
/** B-327: the last thing the machine's auto-update did, or why it did nothing. */
|
|
1081
|
+
autoUpdate: z.z.object({
|
|
1082
|
+
state: z.z.union([z.z.enum(["installing", "installed", "failed", "skipped"]), z.z.string()]),
|
|
1083
|
+
version: z.z.string().nullable(),
|
|
1084
|
+
detail: z.z.string().optional(),
|
|
1085
|
+
at: z.z.number()
|
|
1086
|
+
}).nullable().optional()
|
|
1080
1087
|
});
|
|
1081
1088
|
const WebTerminalListItemSchema = z.z.object({
|
|
1082
1089
|
id: z.z.string(),
|
|
@@ -1673,7 +1680,7 @@ class RpcHandlerManager {
|
|
|
1673
1680
|
}
|
|
1674
1681
|
}
|
|
1675
1682
|
|
|
1676
|
-
const __dirname$1 = path$1.dirname(url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('types-
|
|
1683
|
+
const __dirname$1 = path$1.dirname(url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('types-C5kEpkcZ.cjs', document.baseURI).href))));
|
|
1677
1684
|
function projectPath() {
|
|
1678
1685
|
const path = path$1.resolve(__dirname$1, "..");
|
|
1679
1686
|
return path;
|
|
@@ -9856,6 +9863,49 @@ class SnapshotStore {
|
|
|
9856
9863
|
}
|
|
9857
9864
|
}
|
|
9858
9865
|
|
|
9866
|
+
const OUTPUT_COALESCE_MS = 16;
|
|
9867
|
+
const OUTPUT_COALESCE_MAX_BYTES = 64 * 1024;
|
|
9868
|
+
function createOutputCoalescer({ maxDelayMs, maxBytes } = {
|
|
9869
|
+
maxDelayMs: OUTPUT_COALESCE_MS,
|
|
9870
|
+
maxBytes: OUTPUT_COALESCE_MAX_BYTES
|
|
9871
|
+
}) {
|
|
9872
|
+
let buffered = [];
|
|
9873
|
+
let bufferedBytes = 0;
|
|
9874
|
+
let firstBufferedAt = 0;
|
|
9875
|
+
let lastEmitAt = Number.NEGATIVE_INFINITY;
|
|
9876
|
+
const drain = (now) => {
|
|
9877
|
+
if (bufferedBytes === 0) return null;
|
|
9878
|
+
const out = buffered.length === 1 ? buffered[0] : Buffer.concat(buffered, bufferedBytes);
|
|
9879
|
+
buffered = [];
|
|
9880
|
+
bufferedBytes = 0;
|
|
9881
|
+
firstBufferedAt = 0;
|
|
9882
|
+
lastEmitAt = now;
|
|
9883
|
+
return out;
|
|
9884
|
+
};
|
|
9885
|
+
return {
|
|
9886
|
+
push(data, now) {
|
|
9887
|
+
if (data.length === 0) return null;
|
|
9888
|
+
if (bufferedBytes === 0 && now - lastEmitAt >= maxDelayMs) {
|
|
9889
|
+
lastEmitAt = now;
|
|
9890
|
+
return data;
|
|
9891
|
+
}
|
|
9892
|
+
if (bufferedBytes === 0) firstBufferedAt = now;
|
|
9893
|
+
buffered.push(data);
|
|
9894
|
+
bufferedBytes += data.length;
|
|
9895
|
+
return bufferedBytes >= maxBytes ? drain(now) : null;
|
|
9896
|
+
},
|
|
9897
|
+
flush(now) {
|
|
9898
|
+
return drain(now);
|
|
9899
|
+
},
|
|
9900
|
+
dueAt() {
|
|
9901
|
+
return bufferedBytes === 0 ? null : firstBufferedAt + maxDelayMs;
|
|
9902
|
+
},
|
|
9903
|
+
pendingBytes() {
|
|
9904
|
+
return bufferedBytes;
|
|
9905
|
+
}
|
|
9906
|
+
};
|
|
9907
|
+
}
|
|
9908
|
+
|
|
9859
9909
|
const MAX_SEND_KEYS_PAYLOAD_BYTES = 1e3;
|
|
9860
9910
|
function tmuxSingleQuote(text) {
|
|
9861
9911
|
return `'${text.split("'").join("'\\''")}'`;
|
|
@@ -10766,6 +10816,18 @@ class TerminalSession {
|
|
|
10766
10816
|
lastOutputAt;
|
|
10767
10817
|
cols;
|
|
10768
10818
|
rows;
|
|
10819
|
+
/**
|
|
10820
|
+
* B-334: `%output` arrives as one message per producer write — pi's startup
|
|
10821
|
+
* frame measured 1029 chunks of a median 9 bytes. Merging them before they
|
|
10822
|
+
* are given a seq is what keeps the wire (and the web's write chain) from
|
|
10823
|
+
* carrying a thousand frames for 12 KB. See outputCoalescer.ts.
|
|
10824
|
+
*/
|
|
10825
|
+
coalescer = createOutputCoalescer();
|
|
10826
|
+
flushTimer = null;
|
|
10827
|
+
/** Set by the manager right after construction: how a merged chunk reaches
|
|
10828
|
+
* the subscribers. Left undefined ⇒ the session buffers and drops nothing,
|
|
10829
|
+
* it just has nobody to tell. */
|
|
10830
|
+
onOutputChunk;
|
|
10769
10831
|
constructor(id, transport, tmuxSession, cols, rows) {
|
|
10770
10832
|
this.id = id;
|
|
10771
10833
|
this.transport = transport;
|
|
@@ -10812,6 +10874,61 @@ class TerminalSession {
|
|
|
10812
10874
|
}
|
|
10813
10875
|
return chunk;
|
|
10814
10876
|
}
|
|
10877
|
+
/**
|
|
10878
|
+
* The live-output entry point (B-334). Every `%output` / pty chunk goes
|
|
10879
|
+
* through here instead of straight to `ingest`: the coalescer decides
|
|
10880
|
+
* whether this byte run is emitted now (the common interactive case — an
|
|
10881
|
+
* echo after an idle window pays zero extra latency) or merged into the
|
|
10882
|
+
* frame currently forming. Merging is byte-exact concatenation, so one seq
|
|
10883
|
+
* covering the merged run is indistinguishable from tmux having handed us
|
|
10884
|
+
* one bigger read — the ring/replay/gap protocol is untouched.
|
|
10885
|
+
*/
|
|
10886
|
+
pushOutput(data) {
|
|
10887
|
+
const ready = this.coalescer.push(data, Date.now());
|
|
10888
|
+
if (ready) {
|
|
10889
|
+
this.clearFlushTimer();
|
|
10890
|
+
this.emitOutput(ready);
|
|
10891
|
+
}
|
|
10892
|
+
this.armFlushTimer();
|
|
10893
|
+
}
|
|
10894
|
+
/**
|
|
10895
|
+
* Emit whatever is buffered right now. MUST be called before anything that
|
|
10896
|
+
* reads or changes the screen's identity, because buffered bytes have not
|
|
10897
|
+
* been ingested yet and therefore own no seq:
|
|
10898
|
+
* - the capture anchor (`runCaptureBatch`) — pre-anchor output is already
|
|
10899
|
+
* inside the capture, so it has to own a seq <= `seqAtAnchor` or the
|
|
10900
|
+
* client applies it a second time on top of the restore;
|
|
10901
|
+
* - `resizeHeadless` — those bytes were produced at the OLD size;
|
|
10902
|
+
* - transport exit — otherwise the last frame before a shell dies is lost.
|
|
10903
|
+
*/
|
|
10904
|
+
flushOutput() {
|
|
10905
|
+
this.clearFlushTimer();
|
|
10906
|
+
const ready = this.coalescer.flush(Date.now());
|
|
10907
|
+
if (ready) this.emitOutput(ready);
|
|
10908
|
+
}
|
|
10909
|
+
emitOutput(data) {
|
|
10910
|
+
const chunk = this.ingest(data);
|
|
10911
|
+
this.onOutputChunk?.(chunk);
|
|
10912
|
+
}
|
|
10913
|
+
armFlushTimer() {
|
|
10914
|
+
const due = this.coalescer.dueAt();
|
|
10915
|
+
if (due === null) {
|
|
10916
|
+
this.clearFlushTimer();
|
|
10917
|
+
return;
|
|
10918
|
+
}
|
|
10919
|
+
if (this.flushTimer) return;
|
|
10920
|
+
const timer = setTimeout(() => {
|
|
10921
|
+
this.flushTimer = null;
|
|
10922
|
+
this.flushOutput();
|
|
10923
|
+
}, Math.max(0, due - Date.now()));
|
|
10924
|
+
timer.unref?.();
|
|
10925
|
+
this.flushTimer = timer;
|
|
10926
|
+
}
|
|
10927
|
+
clearFlushTimer() {
|
|
10928
|
+
if (!this.flushTimer) return;
|
|
10929
|
+
clearTimeout(this.flushTimer);
|
|
10930
|
+
this.flushTimer = null;
|
|
10931
|
+
}
|
|
10815
10932
|
/**
|
|
10816
10933
|
* Write a RESTORE payload (the open capture) into the authoritative screen
|
|
10817
10934
|
* WITHOUT giving it a seq: it is not a live chunk, so it must not enter the
|
|
@@ -10831,6 +10948,7 @@ class TerminalSession {
|
|
|
10831
10948
|
/** Keep the authoritative screen's dimensions in lockstep with the terminal
|
|
10832
10949
|
* so a later snapshot serialize() reflects the real geometry. */
|
|
10833
10950
|
resizeHeadless(cols, rows) {
|
|
10951
|
+
this.flushOutput();
|
|
10834
10952
|
this.cols = cols;
|
|
10835
10953
|
this.rows = rows;
|
|
10836
10954
|
try {
|
|
@@ -10910,6 +11028,7 @@ class TerminalSession {
|
|
|
10910
11028
|
} catch {
|
|
10911
11029
|
}
|
|
10912
11030
|
}
|
|
11031
|
+
this.clearFlushTimer();
|
|
10913
11032
|
try {
|
|
10914
11033
|
this.headless.dispose();
|
|
10915
11034
|
} catch {
|
|
@@ -11761,14 +11880,16 @@ class WebTerminalManager {
|
|
|
11761
11880
|
client: void 0
|
|
11762
11881
|
// replaced below
|
|
11763
11882
|
}, tmuxSession, cols, rows);
|
|
11883
|
+
created.onOutputChunk = (chunk) => {
|
|
11884
|
+
this.emit("terminal-output", { terminalId: id, data: chunk.data, seq: chunk.seq });
|
|
11885
|
+
this.noteActivity();
|
|
11886
|
+
};
|
|
11764
11887
|
const client = new ControlClient(tmuxSession, env, {
|
|
11765
11888
|
onOutput: (pane, data) => {
|
|
11766
11889
|
if (this.terminals.get(id) !== created) return;
|
|
11767
11890
|
if (!created.ingesting) return;
|
|
11768
11891
|
if (created.paneId && pane !== created.paneId) return;
|
|
11769
|
-
|
|
11770
|
-
this.emit("terminal-output", { terminalId: id, data: chunk.data, seq: chunk.seq });
|
|
11771
|
-
this.noteActivity();
|
|
11892
|
+
created.pushOutput(data);
|
|
11772
11893
|
},
|
|
11773
11894
|
onNotification: (name, args2) => {
|
|
11774
11895
|
if (this.terminals.get(id) !== created) return;
|
|
@@ -11790,6 +11911,7 @@ class WebTerminalManager {
|
|
|
11790
11911
|
},
|
|
11791
11912
|
onExit: (code) => {
|
|
11792
11913
|
if (this.terminals.get(id) !== created) return;
|
|
11914
|
+
created.flushOutput();
|
|
11793
11915
|
this.terminals.delete(id);
|
|
11794
11916
|
this.snapshots.drop(id);
|
|
11795
11917
|
created.dispose();
|
|
@@ -11810,14 +11932,17 @@ class WebTerminalManager {
|
|
|
11810
11932
|
}
|
|
11811
11933
|
}
|
|
11812
11934
|
const created = new TerminalSession(id, { kind: "pty", pty: proc }, void 0, cols, rows);
|
|
11813
|
-
|
|
11814
|
-
if (this.terminals.get(id) !== created) return;
|
|
11815
|
-
const chunk = created.ingest(Buffer.from(data, "utf8"));
|
|
11935
|
+
created.onOutputChunk = (chunk) => {
|
|
11816
11936
|
this.emit("terminal-output", { terminalId: id, data: chunk.data, seq: chunk.seq });
|
|
11817
11937
|
this.noteActivity();
|
|
11938
|
+
};
|
|
11939
|
+
proc.onData((data) => {
|
|
11940
|
+
if (this.terminals.get(id) !== created) return;
|
|
11941
|
+
created.pushOutput(Buffer.from(data, "utf8"));
|
|
11818
11942
|
});
|
|
11819
11943
|
proc.onExit(({ exitCode }) => {
|
|
11820
11944
|
if (this.terminals.get(id) !== created) return;
|
|
11945
|
+
created.flushOutput();
|
|
11821
11946
|
this.terminals.delete(id);
|
|
11822
11947
|
this.snapshots.drop(id);
|
|
11823
11948
|
created.dispose();
|
|
@@ -11961,6 +12086,7 @@ class WebTerminalManager {
|
|
|
11961
12086
|
command: c.command,
|
|
11962
12087
|
label: c.key,
|
|
11963
12088
|
onBlock: c.key === "anchor" ? () => {
|
|
12089
|
+
session.flushOutput();
|
|
11964
12090
|
seqAtAnchor = session.seq;
|
|
11965
12091
|
if (fresh) session.ingesting = true;
|
|
11966
12092
|
} : void 0
|
|
@@ -14431,6 +14557,15 @@ class ApiMachineClient {
|
|
|
14431
14557
|
// recover account material or impersonate a Web client. (Declared before
|
|
14432
14558
|
// webTerminal so the emit closure can read it.)
|
|
14433
14559
|
encTerminals = /* @__PURE__ */ new Set();
|
|
14560
|
+
/** B-327: an auto-update swaps the process that owns these terminals, so it
|
|
14561
|
+
* waits until there are none. */
|
|
14562
|
+
hasLiveTerminals() {
|
|
14563
|
+
try {
|
|
14564
|
+
return this.webTerminal.buildTerminalList().length > 0;
|
|
14565
|
+
} catch {
|
|
14566
|
+
return true;
|
|
14567
|
+
}
|
|
14568
|
+
}
|
|
14434
14569
|
webTerminal = new WebTerminalManager((event, payload) => {
|
|
14435
14570
|
let out = payload;
|
|
14436
14571
|
if (event === "terminal-output" && this.encTerminals.has(payload.terminalId)) {
|