@zonease/happy 0.6.42 → 0.6.43
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/{api-CIE4_cWd.cjs → api-B-PlVQY6.cjs} +49 -3
- package/dist/{api-Ew6xr81i.mjs → api-BUCtd3cB.mjs} +49 -3
- package/dist/{auth-G9fZpVJ2.cjs → auth-BqGkUXvq.cjs} +2 -2
- package/dist/{auth-BzYevJo2.mjs → auth-DQH6q_q-.mjs} +4 -4
- package/dist/{auth-Dor79zTL.cjs → auth-OL3nNcDX.cjs} +4 -4
- package/dist/{auth-Q2STUNI-.mjs → auth-qM2eojWx.mjs} +2 -2
- package/dist/{browser-qDIIAL7S.cjs → browser-CY7VNU0C.cjs} +1 -1
- package/dist/{browser-BI7s-V8E.mjs → browser-D5RN_Axa.mjs} +1 -1
- package/dist/{claudeLocal-Db2tDC4X.mjs → claudeLocal-BXK_vQXS.mjs} +1 -1
- package/dist/{claudeLocal-f4uBLJaM.cjs → claudeLocal-HAXk0deK.cjs} +1 -1
- package/dist/{config-CHjDs8AS.mjs → config-2wMjzcHl.mjs} +1 -1
- package/dist/{config-CSBlEik9.cjs → config-CaKxWGVe.cjs} +1 -1
- package/dist/{connect-O_nA5BOC.mjs → connect-BAunPyp_.mjs} +4 -4
- package/dist/{connect-CJoTliii.cjs → connect-Dt1vY1BC.cjs} +4 -4
- package/dist/{controlClient-DoS9JqQC.mjs → controlClient-BzzTNSfl.mjs} +1 -1
- package/dist/{controlClient-CEz_p1zc.cjs → controlClient-yTkpwcOq.cjs} +1 -1
- package/dist/{cursorApprovalHook-DRAHfTXU.cjs → cursorApprovalHook-B2chnVni.cjs} +29 -11
- package/dist/{cursorApprovalHook-B0v1kGa7.mjs → cursorApprovalHook-BDLPzI5l.mjs} +29 -11
- package/dist/{cursorApprovalServer-JjPkdjGR.mjs → cursorApprovalServer-Ba1yOUCA.mjs} +109 -10
- package/dist/{cursorApprovalServer-DzY8yJlI.cjs → cursorApprovalServer-xwxVGL3u.cjs} +109 -8
- package/dist/{deviceKeys-B4aqjnE6.mjs → deviceKeys-CQyFFPtt.mjs} +2 -2
- package/dist/{deviceKeys-DyUn0bEx.cjs → deviceKeys-CdW-HPnz.cjs} +2 -2
- package/dist/{doctor-BJSuVRUZ.cjs → doctor-D4xWXiE7.cjs} +2 -2
- package/dist/{doctor-DRnft_5-.mjs → doctor-DDT2TXHH.mjs} +2 -2
- package/dist/{downloadImage-Cijmufpr.cjs → downloadImage-3A6zY5AX.cjs} +1 -372
- package/dist/downloadImage-BqNp0l7y.mjs +485 -0
- package/dist/{enroll-CysDL6ee.mjs → enroll-BlZ0giJI.mjs} +3 -3
- package/dist/{enroll-C2gunHdt.cjs → enroll-DeYs89Ic.cjs} +3 -3
- package/dist/{evidence-DsQ-h-_W.cjs → evidence-Bn1JXtdz.cjs} +1 -1
- package/dist/{evidence-DPutCuUr.mjs → evidence-PUnN9yPK.mjs} +1 -1
- package/dist/{formatImageMessage-6aV9YFWr.mjs → formatImageMessage-BRHeLf0-.mjs} +1 -1
- package/dist/{formatImageMessage-BPK_Ivfe.cjs → formatImageMessage-bVFGFDJl.cjs} +1 -1
- package/dist/index.cjs +50 -46
- package/dist/index.mjs +50 -46
- package/dist/{install-BsTA2tZn.mjs → install-BLPNuSeM.mjs} +2 -2
- package/dist/{install-DBg0xQ3g.mjs → install-BOIcR_Wr.mjs} +1 -1
- package/dist/{install-Tyhs6rUp.cjs → install-Jrs6YUu8.cjs} +1 -1
- package/dist/{install-DlOppA-e.cjs → install-Q-YMwwwg.cjs} +2 -2
- package/dist/lib.cjs +3 -3
- package/dist/lib.d.cts +1 -0
- package/dist/lib.d.mts +1 -0
- package/dist/lib.mjs +3 -3
- package/dist/{loadableToolOutput-DPGTtKJM.cjs → loadableToolOutput-B3qpMqXT.cjs} +2 -2
- package/dist/{loadableToolOutput-2dMPAp4N.mjs → loadableToolOutput-DzReWITb.mjs} +2 -2
- package/dist/{persistence-BcQmjobZ.cjs → persistence-D7zNFI-d.cjs} +1 -1
- package/dist/{persistence-D9tMm6bj.mjs → persistence-DbLMvLvk.mjs} +1 -1
- package/dist/{push-Cnm6JQMD.cjs → push-RT6Y0Hr3.cjs} +6 -6
- package/dist/{push-Dxsugkes.mjs → push-z5wQ4Ki_.mjs} +6 -6
- package/dist/registerKillSessionHandler-DmfnJ0zq.mjs +407 -0
- package/dist/registerKillSessionHandler-MoLdSQxM.cjs +411 -0
- package/dist/{run-BEflQaQ2.mjs → run-BFnSUK1o.mjs} +10 -8
- package/dist/{run-CiPWWhXt.cjs → run-C5StYRIB.cjs} +10 -8
- package/dist/{runClaude-BVXsyCHb.cjs → runClaude-ChRp6f5G.cjs} +26 -26
- package/dist/{runClaude-sPkSqHWY.mjs → runClaude-CjENBdrX.mjs} +21 -21
- package/dist/{runCodex-C4rHkIyw.mjs → runCodex-BzQWlRoj.mjs} +26 -26
- package/dist/{runCodex-BAwhdmSA.cjs → runCodex-DcQGyotH.cjs} +28 -28
- package/dist/{runCursor-DiHLWMs8.mjs → runCursor-B73z6MCN.mjs} +210 -34
- package/dist/{runCursor-CD5wC3gA.cjs → runCursor-BlPAxaTy.cjs} +210 -34
- package/dist/{runGemini-B-93gOqB.mjs → runGemini-BPv4UzuF.mjs} +17 -17
- package/dist/{runGemini-Cto-adir.cjs → runGemini-JFqaIC3u.cjs} +19 -19
- package/dist/{runOneShot-BfIzE9W4.cjs → runOneShot-2iV11e9L.cjs} +2 -2
- package/dist/{runOneShot-DGjlYVhR.mjs → runOneShot-DTukim2A.mjs} +2 -2
- package/dist/{serve-CqL6NWDr.cjs → serve-BDwuAIK4.cjs} +6 -6
- package/dist/{serve-ttlqF5jn.mjs → serve-BnlYj5ek.mjs} +6 -6
- package/dist/{session-BZhGpQUJ.cjs → session-Cp9LEESM.cjs} +5 -5
- package/dist/{session-Co0REU9e.mjs → session-gfeFU8CA.mjs} +5 -5
- package/dist/{sessionKeyCache-BwFUGgMs.cjs → sessionKeyCache-3Pme04yL.cjs} +1 -1
- package/dist/{sessionKeyCache-pXTjpETo.mjs → sessionKeyCache-DtBS_Sb3.mjs} +1 -1
- package/dist/{sessionList-DaufR-sA.mjs → sessionList-B1w4BUdv.mjs} +2 -2
- package/dist/{sessionList-fG5uAPzU.cjs → sessionList-BR_5UDZJ.cjs} +2 -2
- package/dist/{sessionSummary-CjZPt6nr.cjs → sessionSummary-DLweYgHO.cjs} +3 -3
- package/dist/{sessionSummary-Dv6dPABg.mjs → sessionSummary-E-a2bg8W.mjs} +3 -3
- package/dist/{setupOfflineReconnection-DW5il97B.mjs → setupOfflineReconnection-DHwthFtd.mjs} +5 -3
- package/dist/{setupOfflineReconnection-B6coH9QN.cjs → setupOfflineReconnection-Dkp00dC9.cjs} +7 -5
- package/dist/{spawnHappyCLI-Cfu7C1uM.cjs → spawnHappyCLI-C2uY9WV-.cjs} +1 -1
- package/dist/{spawnHappyCLI-DhUeycct.mjs → spawnHappyCLI-Dt7fbmbk.mjs} +1 -1
- package/dist/{ssh-8tPIKk-i.mjs → ssh-C-nEZiGP.mjs} +5 -5
- package/dist/{ssh-C4YTSHXL.cjs → ssh-CsnS89Lr.cjs} +5 -5
- package/dist/{task-CH-oidFy.mjs → task-B-8_QGGX.mjs} +6 -6
- package/dist/{task-DFW-PecP.cjs → task-lrLb4FCL.cjs} +6 -6
- package/dist/{uninstall-CeioRZNI.mjs → uninstall-CirMt_WC.mjs} +2 -2
- package/dist/{uninstall-yTSL3X6Y.cjs → uninstall-DMjUlEXT.cjs} +2 -2
- package/dist/{update-Derd2hoX.mjs → update-CfXbYshs.mjs} +3 -3
- package/dist/{update-Bju28vNP.cjs → update-mx2p28IP.cjs} +3 -3
- package/package.json +1 -1
- package/dist/downloadImage-BpVF7A79.mjs +0 -854
- package/dist/gitWorktree-C6jLoaMw.cjs +0 -39
- package/dist/gitWorktree-CzJDU2BV.mjs +0 -37
package/dist/index.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chalk = require('chalk');
|
|
4
|
-
var logger = require('./persistence-
|
|
4
|
+
var logger = require('./persistence-D7zNFI-d.cjs');
|
|
5
5
|
var z = require('zod');
|
|
6
6
|
var node_child_process = require('node:child_process');
|
|
7
7
|
require('node:fs/promises');
|
|
@@ -13,8 +13,8 @@ require('tweetnacl');
|
|
|
13
13
|
require('fs');
|
|
14
14
|
|
|
15
15
|
async function spawnAndWaitForDaemon() {
|
|
16
|
-
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-
|
|
17
|
-
const { checkIfDaemonRunningAndCleanupStaleState } = await Promise.resolve().then(function () { return require('./controlClient-
|
|
16
|
+
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-C2uY9WV-.cjs'); }).then(function (n) { return n.spawnHappyCLI$1; });
|
|
17
|
+
const { checkIfDaemonRunningAndCleanupStaleState } = await Promise.resolve().then(function () { return require('./controlClient-yTkpwcOq.cjs'); });
|
|
18
18
|
const child = spawnHappyCLI(["daemon", "start-sync"], {
|
|
19
19
|
detached: true,
|
|
20
20
|
stdio: "ignore"
|
|
@@ -37,7 +37,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
37
37
|
if (!args.includes("--version")) ;
|
|
38
38
|
if (subcommand === "orchestrator-oneshot") {
|
|
39
39
|
try {
|
|
40
|
-
const { runOrchestratorOneShot } = await Promise.resolve().then(function () { return require('./runOneShot-
|
|
40
|
+
const { runOrchestratorOneShot } = await Promise.resolve().then(function () { return require('./runOneShot-2iV11e9L.cjs'); });
|
|
41
41
|
const exitCode = await runOrchestratorOneShot(args.slice(1));
|
|
42
42
|
process.exit(exitCode);
|
|
43
43
|
} catch (error) {
|
|
@@ -50,7 +50,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
50
50
|
return;
|
|
51
51
|
} else if (subcommand === "doctor") {
|
|
52
52
|
const { killRunawayHappyProcesses } = await Promise.resolve().then(function () { return require('./doctor-C08m5Z9f.cjs'); });
|
|
53
|
-
const { runDoctorCommand } = await Promise.resolve().then(function () { return require('./doctor-
|
|
53
|
+
const { runDoctorCommand } = await Promise.resolve().then(function () { return require('./doctor-D4xWXiE7.cjs'); });
|
|
54
54
|
if (args[1] === "clean") {
|
|
55
55
|
const result = await killRunawayHappyProcesses();
|
|
56
56
|
console.log(`Cleaned up ${result.killed} runaway processes`);
|
|
@@ -63,7 +63,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
63
63
|
return;
|
|
64
64
|
} else if (subcommand === "auth") {
|
|
65
65
|
try {
|
|
66
|
-
const { handleAuthCommand } = await Promise.resolve().then(function () { return require('./auth-
|
|
66
|
+
const { handleAuthCommand } = await Promise.resolve().then(function () { return require('./auth-OL3nNcDX.cjs'); });
|
|
67
67
|
await handleAuthCommand(args.slice(1));
|
|
68
68
|
} catch (error) {
|
|
69
69
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -75,7 +75,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
75
75
|
return;
|
|
76
76
|
} else if (subcommand === "connect") {
|
|
77
77
|
try {
|
|
78
|
-
const { handleConnectCommand } = await Promise.resolve().then(function () { return require('./connect-
|
|
78
|
+
const { handleConnectCommand } = await Promise.resolve().then(function () { return require('./connect-Dt1vY1BC.cjs'); });
|
|
79
79
|
await handleConnectCommand(args.slice(1));
|
|
80
80
|
} catch (error) {
|
|
81
81
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -86,11 +86,11 @@ async function spawnAndWaitForDaemon() {
|
|
|
86
86
|
}
|
|
87
87
|
return;
|
|
88
88
|
} else if (subcommand === "codex") {
|
|
89
|
-
const { authAndSetupMachineIfNeeded } = await Promise.resolve().then(function () { return require('./auth-
|
|
90
|
-
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await Promise.resolve().then(function () { return require('./controlClient-
|
|
91
|
-
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-
|
|
89
|
+
const { authAndSetupMachineIfNeeded } = await Promise.resolve().then(function () { return require('./auth-BqGkUXvq.cjs'); });
|
|
90
|
+
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await Promise.resolve().then(function () { return require('./controlClient-yTkpwcOq.cjs'); });
|
|
91
|
+
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-C2uY9WV-.cjs'); }).then(function (n) { return n.spawnHappyCLI$1; });
|
|
92
92
|
try {
|
|
93
|
-
const { runCodex } = await Promise.resolve().then(function () { return require('./runCodex-
|
|
93
|
+
const { runCodex } = await Promise.resolve().then(function () { return require('./runCodex-DcQGyotH.cjs'); });
|
|
94
94
|
let startedBy = void 0;
|
|
95
95
|
for (let i = 1; i < args.length; i++) {
|
|
96
96
|
if (args[i] === "--started-by") {
|
|
@@ -121,21 +121,24 @@ async function spawnAndWaitForDaemon() {
|
|
|
121
121
|
}
|
|
122
122
|
return;
|
|
123
123
|
} else if (subcommand === "cursor-approval-hook") {
|
|
124
|
-
const { runCursorApprovalHook } = await Promise.resolve().then(function () { return require('./cursorApprovalHook-
|
|
124
|
+
const { runCursorApprovalHook } = await Promise.resolve().then(function () { return require('./cursorApprovalHook-B2chnVni.cjs'); });
|
|
125
125
|
await runCursorApprovalHook();
|
|
126
126
|
return;
|
|
127
127
|
} else if (subcommand === "cursor") {
|
|
128
|
-
const { authAndSetupMachineIfNeeded } = await Promise.resolve().then(function () { return require('./auth-
|
|
129
|
-
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await Promise.resolve().then(function () { return require('./controlClient-
|
|
130
|
-
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-
|
|
128
|
+
const { authAndSetupMachineIfNeeded } = await Promise.resolve().then(function () { return require('./auth-BqGkUXvq.cjs'); });
|
|
129
|
+
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await Promise.resolve().then(function () { return require('./controlClient-yTkpwcOq.cjs'); });
|
|
130
|
+
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-C2uY9WV-.cjs'); }).then(function (n) { return n.spawnHappyCLI$1; });
|
|
131
131
|
try {
|
|
132
|
-
const { runCursor } = await Promise.resolve().then(function () { return require('./runCursor-
|
|
132
|
+
const { runCursor } = await Promise.resolve().then(function () { return require('./runCursor-BlPAxaTy.cjs'); });
|
|
133
133
|
let startedBy = void 0;
|
|
134
134
|
let model = null;
|
|
135
|
+
let resumeChatId = null;
|
|
135
136
|
const promptParts = [];
|
|
136
137
|
for (let i = 1; i < args.length; i++) {
|
|
137
138
|
if (args[i] === "--started-by") {
|
|
138
139
|
startedBy = args[++i];
|
|
140
|
+
} else if (args[i] === "--resume") {
|
|
141
|
+
resumeChatId = args[++i] ?? null;
|
|
139
142
|
} else if (args[i] === "--model") {
|
|
140
143
|
model = args[++i] ?? null;
|
|
141
144
|
} else if (args[i] === "--happy-starting-mode") {
|
|
@@ -160,6 +163,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
160
163
|
credentials,
|
|
161
164
|
startedBy,
|
|
162
165
|
model,
|
|
166
|
+
resumeChatId,
|
|
163
167
|
initialPrompt: promptParts.length > 0 ? promptParts.join(" ") : void 0
|
|
164
168
|
});
|
|
165
169
|
} catch (error) {
|
|
@@ -171,9 +175,9 @@ async function spawnAndWaitForDaemon() {
|
|
|
171
175
|
}
|
|
172
176
|
return;
|
|
173
177
|
} else if (subcommand === "gemini") {
|
|
174
|
-
const { authAndSetupMachineIfNeeded } = await Promise.resolve().then(function () { return require('./auth-
|
|
175
|
-
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await Promise.resolve().then(function () { return require('./controlClient-
|
|
176
|
-
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-
|
|
178
|
+
const { authAndSetupMachineIfNeeded } = await Promise.resolve().then(function () { return require('./auth-BqGkUXvq.cjs'); });
|
|
179
|
+
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await Promise.resolve().then(function () { return require('./controlClient-yTkpwcOq.cjs'); });
|
|
180
|
+
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-C2uY9WV-.cjs'); }).then(function (n) { return n.spawnHappyCLI$1; });
|
|
177
181
|
const geminiSubcommand = args[1];
|
|
178
182
|
if (geminiSubcommand === "model" && args[2] === "set" && args[3]) {
|
|
179
183
|
const modelName = args[3];
|
|
@@ -247,9 +251,9 @@ async function spawnAndWaitForDaemon() {
|
|
|
247
251
|
if (geminiSubcommand === "project" && args[2] === "set" && args[3]) {
|
|
248
252
|
const projectId = args[3];
|
|
249
253
|
try {
|
|
250
|
-
const { saveGoogleCloudProjectToConfig } = await Promise.resolve().then(function () { return require('./config-
|
|
251
|
-
const { readCredentials: readCredentials2 } = await Promise.resolve().then(function () { return require('./persistence-
|
|
252
|
-
const { ApiClient } = await Promise.resolve().then(function () { return require('./api-
|
|
254
|
+
const { saveGoogleCloudProjectToConfig } = await Promise.resolve().then(function () { return require('./config-CaKxWGVe.cjs'); });
|
|
255
|
+
const { readCredentials: readCredentials2 } = await Promise.resolve().then(function () { return require('./persistence-D7zNFI-d.cjs'); }).then(function (n) { return n.persistence; });
|
|
256
|
+
const { ApiClient } = await Promise.resolve().then(function () { return require('./api-B-PlVQY6.cjs'); }).then(function (n) { return n.api; });
|
|
253
257
|
let userEmail = void 0;
|
|
254
258
|
try {
|
|
255
259
|
const credentials = await readCredentials2();
|
|
@@ -280,7 +284,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
280
284
|
}
|
|
281
285
|
if (geminiSubcommand === "project" && args[2] === "get") {
|
|
282
286
|
try {
|
|
283
|
-
const { readGeminiLocalConfig } = await Promise.resolve().then(function () { return require('./config-
|
|
287
|
+
const { readGeminiLocalConfig } = await Promise.resolve().then(function () { return require('./config-CaKxWGVe.cjs'); });
|
|
284
288
|
const config = readGeminiLocalConfig();
|
|
285
289
|
if (config.googleCloudProject) {
|
|
286
290
|
console.log(`Current Google Cloud Project: ${config.googleCloudProject}`);
|
|
@@ -320,7 +324,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
320
324
|
process.exit(0);
|
|
321
325
|
}
|
|
322
326
|
try {
|
|
323
|
-
const { runGemini } = await Promise.resolve().then(function () { return require('./runGemini-
|
|
327
|
+
const { runGemini } = await Promise.resolve().then(function () { return require('./runGemini-JFqaIC3u.cjs'); });
|
|
324
328
|
let startedBy = void 0;
|
|
325
329
|
for (let i = 1; i < args.length; i++) {
|
|
326
330
|
if (args[i] === "--started-by") {
|
|
@@ -352,7 +356,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
352
356
|
return;
|
|
353
357
|
} else if (subcommand === "update") {
|
|
354
358
|
try {
|
|
355
|
-
const { handleUpdateCommand } = await Promise.resolve().then(function () { return require('./update-
|
|
359
|
+
const { handleUpdateCommand } = await Promise.resolve().then(function () { return require('./update-mx2p28IP.cjs'); });
|
|
356
360
|
await handleUpdateCommand();
|
|
357
361
|
} catch (error) {
|
|
358
362
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -365,7 +369,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
365
369
|
} else if (subcommand === "logout") {
|
|
366
370
|
console.log(chalk.yellow('Note: "happy logout" is deprecated. Use "happy auth logout" instead.\n'));
|
|
367
371
|
try {
|
|
368
|
-
const { handleAuthCommand } = await Promise.resolve().then(function () { return require('./auth-
|
|
372
|
+
const { handleAuthCommand } = await Promise.resolve().then(function () { return require('./auth-OL3nNcDX.cjs'); });
|
|
369
373
|
await handleAuthCommand(["logout"]);
|
|
370
374
|
} catch (error) {
|
|
371
375
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -388,7 +392,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
388
392
|
return;
|
|
389
393
|
} else if (subcommand === "session") {
|
|
390
394
|
try {
|
|
391
|
-
const { handleSessionCommand } = await Promise.resolve().then(function () { return require('./session-
|
|
395
|
+
const { handleSessionCommand } = await Promise.resolve().then(function () { return require('./session-Cp9LEESM.cjs'); });
|
|
392
396
|
await handleSessionCommand(args.slice(1));
|
|
393
397
|
} catch (error) {
|
|
394
398
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -400,7 +404,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
400
404
|
return;
|
|
401
405
|
} else if (subcommand === "task") {
|
|
402
406
|
try {
|
|
403
|
-
const { handleTaskCommand } = await Promise.resolve().then(function () { return require('./task-
|
|
407
|
+
const { handleTaskCommand } = await Promise.resolve().then(function () { return require('./task-lrLb4FCL.cjs'); });
|
|
404
408
|
await handleTaskCommand(args.slice(1));
|
|
405
409
|
} catch (error) {
|
|
406
410
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -448,7 +452,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
448
452
|
return;
|
|
449
453
|
} else if (subcommand === "evidence") {
|
|
450
454
|
try {
|
|
451
|
-
const { handleEvidenceCommand } = await Promise.resolve().then(function () { return require('./evidence-
|
|
455
|
+
const { handleEvidenceCommand } = await Promise.resolve().then(function () { return require('./evidence-Bn1JXtdz.cjs'); });
|
|
452
456
|
await handleEvidenceCommand(args.slice(1));
|
|
453
457
|
} catch (error) {
|
|
454
458
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -465,7 +469,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
465
469
|
process.exit(1);
|
|
466
470
|
}
|
|
467
471
|
try {
|
|
468
|
-
const { runMcpServe } = await Promise.resolve().then(function () { return require('./serve-
|
|
472
|
+
const { runMcpServe } = await Promise.resolve().then(function () { return require('./serve-BDwuAIK4.cjs'); });
|
|
469
473
|
await runMcpServe();
|
|
470
474
|
} catch (error) {
|
|
471
475
|
process.stderr.write(`[happy-mcp] fatal: ${error instanceof Error ? error.message : "unknown error"}
|
|
@@ -479,7 +483,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
479
483
|
console.error(chalk.red("Error:"), 'Not authenticated. Run "happy auth" first.');
|
|
480
484
|
process.exit(1);
|
|
481
485
|
}
|
|
482
|
-
const { parseSshArgs, runOnDevice, sshDevice, sshPickAndConnect } = await Promise.resolve().then(function () { return require('./ssh-
|
|
486
|
+
const { parseSshArgs, runOnDevice, sshDevice, sshPickAndConnect } = await Promise.resolve().then(function () { return require('./ssh-CsnS89Lr.cjs'); });
|
|
483
487
|
const { target, command, timeoutMs, stream } = parseSshArgs(args.slice(1));
|
|
484
488
|
try {
|
|
485
489
|
if (command) {
|
|
@@ -500,7 +504,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
500
504
|
} else if (subcommand === "device") {
|
|
501
505
|
const deviceSubcommand = args[1];
|
|
502
506
|
if (deviceSubcommand === "push") {
|
|
503
|
-
const { pushToDevice } = await Promise.resolve().then(function () { return require('./push-
|
|
507
|
+
const { pushToDevice } = await Promise.resolve().then(function () { return require('./push-RT6Y0Hr3.cjs'); });
|
|
504
508
|
const credentials = await logger.readCredentials();
|
|
505
509
|
if (!credentials) {
|
|
506
510
|
console.error(chalk.red("Error:"), 'Not authenticated. Run "happy auth" first.');
|
|
@@ -514,8 +518,8 @@ async function spawnAndWaitForDaemon() {
|
|
|
514
518
|
process.exit(await pushToDevice(credentials, target, localPath, remotePath));
|
|
515
519
|
}
|
|
516
520
|
if (deviceSubcommand === "enroll") {
|
|
517
|
-
const { enrollDevice } = await Promise.resolve().then(function () { return require('./enroll-
|
|
518
|
-
const { install } = await Promise.resolve().then(function () { return require('./install-
|
|
521
|
+
const { enrollDevice } = await Promise.resolve().then(function () { return require('./enroll-DeYs89Ic.cjs'); });
|
|
522
|
+
const { install } = await Promise.resolve().then(function () { return require('./install-Q-YMwwwg.cjs'); });
|
|
519
523
|
const token = args[2];
|
|
520
524
|
if (!token) {
|
|
521
525
|
console.error(chalk.red("Error:"), "Missing enrollment token. Usage: happy device enroll <token>");
|
|
@@ -545,12 +549,12 @@ ${chalk.bold("Usage:")}
|
|
|
545
549
|
`);
|
|
546
550
|
process.exit(0);
|
|
547
551
|
} else if (subcommand === "daemon") {
|
|
548
|
-
const { startDaemon } = await Promise.resolve().then(function () { return require('./run-
|
|
549
|
-
const { install } = await Promise.resolve().then(function () { return require('./install-
|
|
550
|
-
const { uninstall } = await Promise.resolve().then(function () { return require('./uninstall-
|
|
551
|
-
const { runDoctorCommand } = await Promise.resolve().then(function () { return require('./doctor-
|
|
552
|
-
const { getLatestDaemonLog } = await Promise.resolve().then(function () { return require('./persistence-
|
|
553
|
-
const { listDaemonSessions, stopDaemonSession, stopDaemon } = await Promise.resolve().then(function () { return require('./controlClient-
|
|
552
|
+
const { startDaemon } = await Promise.resolve().then(function () { return require('./run-C5StYRIB.cjs'); }).then(function (n) { return n.run; });
|
|
553
|
+
const { install } = await Promise.resolve().then(function () { return require('./install-Q-YMwwwg.cjs'); });
|
|
554
|
+
const { uninstall } = await Promise.resolve().then(function () { return require('./uninstall-DMjUlEXT.cjs'); });
|
|
555
|
+
const { runDoctorCommand } = await Promise.resolve().then(function () { return require('./doctor-D4xWXiE7.cjs'); });
|
|
556
|
+
const { getLatestDaemonLog } = await Promise.resolve().then(function () { return require('./persistence-D7zNFI-d.cjs'); }).then(function (n) { return n.logger$1; });
|
|
557
|
+
const { listDaemonSessions, stopDaemonSession, stopDaemon } = await Promise.resolve().then(function () { return require('./controlClient-yTkpwcOq.cjs'); });
|
|
554
558
|
const daemonSubcommand = args[1];
|
|
555
559
|
if (daemonSubcommand === "list") {
|
|
556
560
|
try {
|
|
@@ -755,7 +759,7 @@ ${chalk.gray("\u2500".repeat(60))}
|
|
|
755
759
|
${chalk.bold.cyan("Claude Code Options (from `claude --help`):")}
|
|
756
760
|
`);
|
|
757
761
|
try {
|
|
758
|
-
const { claudeCliPath } = await Promise.resolve().then(function () { return require('./claudeLocal-
|
|
762
|
+
const { claudeCliPath } = await Promise.resolve().then(function () { return require('./claudeLocal-HAXk0deK.cjs'); }).then(function (n) { return n.claudeLocal$1; });
|
|
759
763
|
const claudeHelp = node_child_process.execFileSync(claudeCliPath, ["--help"], { encoding: "utf8" });
|
|
760
764
|
console.log(claudeHelp);
|
|
761
765
|
} catch (e) {
|
|
@@ -785,10 +789,10 @@ ${chalk.bold.cyan("Claude Code Options (from `claude --help`):")}
|
|
|
785
789
|
}
|
|
786
790
|
process.exit(0);
|
|
787
791
|
}
|
|
788
|
-
const { authAndSetupMachineIfNeeded } = await Promise.resolve().then(function () { return require('./auth-
|
|
789
|
-
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await Promise.resolve().then(function () { return require('./controlClient-
|
|
790
|
-
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-
|
|
791
|
-
const { runClaude } = await Promise.resolve().then(function () { return require('./runClaude-
|
|
792
|
+
const { authAndSetupMachineIfNeeded } = await Promise.resolve().then(function () { return require('./auth-BqGkUXvq.cjs'); });
|
|
793
|
+
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await Promise.resolve().then(function () { return require('./controlClient-yTkpwcOq.cjs'); });
|
|
794
|
+
const { spawnHappyCLI } = await Promise.resolve().then(function () { return require('./spawnHappyCLI-C2uY9WV-.cjs'); }).then(function (n) { return n.spawnHappyCLI$1; });
|
|
795
|
+
const { runClaude } = await Promise.resolve().then(function () { return require('./runClaude-ChRp6f5G.cjs'); });
|
|
792
796
|
const {
|
|
793
797
|
credentials
|
|
794
798
|
} = await authAndSetupMachineIfNeeded();
|
|
@@ -862,7 +866,7 @@ ${chalk.bold("Examples:")}
|
|
|
862
866
|
}
|
|
863
867
|
console.log(chalk.blue("\u{1F4F1} Sending push notification..."));
|
|
864
868
|
try {
|
|
865
|
-
const { ApiClient } = await Promise.resolve().then(function () { return require('./api-
|
|
869
|
+
const { ApiClient } = await Promise.resolve().then(function () { return require('./api-B-PlVQY6.cjs'); }).then(function (n) { return n.api; });
|
|
866
870
|
const api = await ApiClient.create(credentials);
|
|
867
871
|
const notificationTitle = title || "Happy AI";
|
|
868
872
|
api.push().sendToAllDevices(
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import{createRequire as _pkgrollCR}from"node:module";const require=_pkgrollCR(import.meta.url);import chalk from 'chalk';
|
|
2
|
-
import { l as logger, i as isDebug, r as readCredentials, a as readSettings, p as packageJson } from './persistence-
|
|
2
|
+
import { l as logger, i as isDebug, r as readCredentials, a as readSettings, p as packageJson } from './persistence-DbLMvLvk.mjs';
|
|
3
3
|
import { z } from 'zod';
|
|
4
4
|
import { execFileSync } from 'node:child_process';
|
|
5
5
|
import 'node:fs/promises';
|
|
@@ -11,8 +11,8 @@ import 'tweetnacl';
|
|
|
11
11
|
import 'fs';
|
|
12
12
|
|
|
13
13
|
async function spawnAndWaitForDaemon() {
|
|
14
|
-
const { spawnHappyCLI } = await import('./spawnHappyCLI-
|
|
15
|
-
const { checkIfDaemonRunningAndCleanupStaleState } = await import('./controlClient-
|
|
14
|
+
const { spawnHappyCLI } = await import('./spawnHappyCLI-Dt7fbmbk.mjs').then(function (n) { return n.a; });
|
|
15
|
+
const { checkIfDaemonRunningAndCleanupStaleState } = await import('./controlClient-BzzTNSfl.mjs');
|
|
16
16
|
const child = spawnHappyCLI(["daemon", "start-sync"], {
|
|
17
17
|
detached: true,
|
|
18
18
|
stdio: "ignore"
|
|
@@ -35,7 +35,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
35
35
|
if (!args.includes("--version")) ;
|
|
36
36
|
if (subcommand === "orchestrator-oneshot") {
|
|
37
37
|
try {
|
|
38
|
-
const { runOrchestratorOneShot } = await import('./runOneShot-
|
|
38
|
+
const { runOrchestratorOneShot } = await import('./runOneShot-DTukim2A.mjs');
|
|
39
39
|
const exitCode = await runOrchestratorOneShot(args.slice(1));
|
|
40
40
|
process.exit(exitCode);
|
|
41
41
|
} catch (error) {
|
|
@@ -48,7 +48,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
48
48
|
return;
|
|
49
49
|
} else if (subcommand === "doctor") {
|
|
50
50
|
const { killRunawayHappyProcesses } = await import('./doctor-ON7pN5G5.mjs');
|
|
51
|
-
const { runDoctorCommand } = await import('./doctor-
|
|
51
|
+
const { runDoctorCommand } = await import('./doctor-DDT2TXHH.mjs');
|
|
52
52
|
if (args[1] === "clean") {
|
|
53
53
|
const result = await killRunawayHappyProcesses();
|
|
54
54
|
console.log(`Cleaned up ${result.killed} runaway processes`);
|
|
@@ -61,7 +61,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
61
61
|
return;
|
|
62
62
|
} else if (subcommand === "auth") {
|
|
63
63
|
try {
|
|
64
|
-
const { handleAuthCommand } = await import('./auth-
|
|
64
|
+
const { handleAuthCommand } = await import('./auth-DQH6q_q-.mjs');
|
|
65
65
|
await handleAuthCommand(args.slice(1));
|
|
66
66
|
} catch (error) {
|
|
67
67
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -73,7 +73,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
73
73
|
return;
|
|
74
74
|
} else if (subcommand === "connect") {
|
|
75
75
|
try {
|
|
76
|
-
const { handleConnectCommand } = await import('./connect-
|
|
76
|
+
const { handleConnectCommand } = await import('./connect-BAunPyp_.mjs');
|
|
77
77
|
await handleConnectCommand(args.slice(1));
|
|
78
78
|
} catch (error) {
|
|
79
79
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -84,11 +84,11 @@ async function spawnAndWaitForDaemon() {
|
|
|
84
84
|
}
|
|
85
85
|
return;
|
|
86
86
|
} else if (subcommand === "codex") {
|
|
87
|
-
const { authAndSetupMachineIfNeeded } = await import('./auth-
|
|
88
|
-
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await import('./controlClient-
|
|
89
|
-
const { spawnHappyCLI } = await import('./spawnHappyCLI-
|
|
87
|
+
const { authAndSetupMachineIfNeeded } = await import('./auth-qM2eojWx.mjs');
|
|
88
|
+
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await import('./controlClient-BzzTNSfl.mjs');
|
|
89
|
+
const { spawnHappyCLI } = await import('./spawnHappyCLI-Dt7fbmbk.mjs').then(function (n) { return n.a; });
|
|
90
90
|
try {
|
|
91
|
-
const { runCodex } = await import('./runCodex-
|
|
91
|
+
const { runCodex } = await import('./runCodex-BzQWlRoj.mjs');
|
|
92
92
|
let startedBy = void 0;
|
|
93
93
|
for (let i = 1; i < args.length; i++) {
|
|
94
94
|
if (args[i] === "--started-by") {
|
|
@@ -119,21 +119,24 @@ async function spawnAndWaitForDaemon() {
|
|
|
119
119
|
}
|
|
120
120
|
return;
|
|
121
121
|
} else if (subcommand === "cursor-approval-hook") {
|
|
122
|
-
const { runCursorApprovalHook } = await import('./cursorApprovalHook-
|
|
122
|
+
const { runCursorApprovalHook } = await import('./cursorApprovalHook-BDLPzI5l.mjs');
|
|
123
123
|
await runCursorApprovalHook();
|
|
124
124
|
return;
|
|
125
125
|
} else if (subcommand === "cursor") {
|
|
126
|
-
const { authAndSetupMachineIfNeeded } = await import('./auth-
|
|
127
|
-
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await import('./controlClient-
|
|
128
|
-
const { spawnHappyCLI } = await import('./spawnHappyCLI-
|
|
126
|
+
const { authAndSetupMachineIfNeeded } = await import('./auth-qM2eojWx.mjs');
|
|
127
|
+
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await import('./controlClient-BzzTNSfl.mjs');
|
|
128
|
+
const { spawnHappyCLI } = await import('./spawnHappyCLI-Dt7fbmbk.mjs').then(function (n) { return n.a; });
|
|
129
129
|
try {
|
|
130
|
-
const { runCursor } = await import('./runCursor-
|
|
130
|
+
const { runCursor } = await import('./runCursor-B73z6MCN.mjs');
|
|
131
131
|
let startedBy = void 0;
|
|
132
132
|
let model = null;
|
|
133
|
+
let resumeChatId = null;
|
|
133
134
|
const promptParts = [];
|
|
134
135
|
for (let i = 1; i < args.length; i++) {
|
|
135
136
|
if (args[i] === "--started-by") {
|
|
136
137
|
startedBy = args[++i];
|
|
138
|
+
} else if (args[i] === "--resume") {
|
|
139
|
+
resumeChatId = args[++i] ?? null;
|
|
137
140
|
} else if (args[i] === "--model") {
|
|
138
141
|
model = args[++i] ?? null;
|
|
139
142
|
} else if (args[i] === "--happy-starting-mode") {
|
|
@@ -158,6 +161,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
158
161
|
credentials,
|
|
159
162
|
startedBy,
|
|
160
163
|
model,
|
|
164
|
+
resumeChatId,
|
|
161
165
|
initialPrompt: promptParts.length > 0 ? promptParts.join(" ") : void 0
|
|
162
166
|
});
|
|
163
167
|
} catch (error) {
|
|
@@ -169,9 +173,9 @@ async function spawnAndWaitForDaemon() {
|
|
|
169
173
|
}
|
|
170
174
|
return;
|
|
171
175
|
} else if (subcommand === "gemini") {
|
|
172
|
-
const { authAndSetupMachineIfNeeded } = await import('./auth-
|
|
173
|
-
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await import('./controlClient-
|
|
174
|
-
const { spawnHappyCLI } = await import('./spawnHappyCLI-
|
|
176
|
+
const { authAndSetupMachineIfNeeded } = await import('./auth-qM2eojWx.mjs');
|
|
177
|
+
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await import('./controlClient-BzzTNSfl.mjs');
|
|
178
|
+
const { spawnHappyCLI } = await import('./spawnHappyCLI-Dt7fbmbk.mjs').then(function (n) { return n.a; });
|
|
175
179
|
const geminiSubcommand = args[1];
|
|
176
180
|
if (geminiSubcommand === "model" && args[2] === "set" && args[3]) {
|
|
177
181
|
const modelName = args[3];
|
|
@@ -245,9 +249,9 @@ async function spawnAndWaitForDaemon() {
|
|
|
245
249
|
if (geminiSubcommand === "project" && args[2] === "set" && args[3]) {
|
|
246
250
|
const projectId = args[3];
|
|
247
251
|
try {
|
|
248
|
-
const { saveGoogleCloudProjectToConfig } = await import('./config-
|
|
249
|
-
const { readCredentials: readCredentials2 } = await import('./persistence-
|
|
250
|
-
const { ApiClient } = await import('./api-
|
|
252
|
+
const { saveGoogleCloudProjectToConfig } = await import('./config-2wMjzcHl.mjs');
|
|
253
|
+
const { readCredentials: readCredentials2 } = await import('./persistence-DbLMvLvk.mjs').then(function (n) { return n.F; });
|
|
254
|
+
const { ApiClient } = await import('./api-BUCtd3cB.mjs').then(function (n) { return n.m; });
|
|
251
255
|
let userEmail = void 0;
|
|
252
256
|
try {
|
|
253
257
|
const credentials = await readCredentials2();
|
|
@@ -278,7 +282,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
278
282
|
}
|
|
279
283
|
if (geminiSubcommand === "project" && args[2] === "get") {
|
|
280
284
|
try {
|
|
281
|
-
const { readGeminiLocalConfig } = await import('./config-
|
|
285
|
+
const { readGeminiLocalConfig } = await import('./config-2wMjzcHl.mjs');
|
|
282
286
|
const config = readGeminiLocalConfig();
|
|
283
287
|
if (config.googleCloudProject) {
|
|
284
288
|
console.log(`Current Google Cloud Project: ${config.googleCloudProject}`);
|
|
@@ -318,7 +322,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
318
322
|
process.exit(0);
|
|
319
323
|
}
|
|
320
324
|
try {
|
|
321
|
-
const { runGemini } = await import('./runGemini-
|
|
325
|
+
const { runGemini } = await import('./runGemini-BPv4UzuF.mjs');
|
|
322
326
|
let startedBy = void 0;
|
|
323
327
|
for (let i = 1; i < args.length; i++) {
|
|
324
328
|
if (args[i] === "--started-by") {
|
|
@@ -350,7 +354,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
350
354
|
return;
|
|
351
355
|
} else if (subcommand === "update") {
|
|
352
356
|
try {
|
|
353
|
-
const { handleUpdateCommand } = await import('./update-
|
|
357
|
+
const { handleUpdateCommand } = await import('./update-CfXbYshs.mjs');
|
|
354
358
|
await handleUpdateCommand();
|
|
355
359
|
} catch (error) {
|
|
356
360
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -363,7 +367,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
363
367
|
} else if (subcommand === "logout") {
|
|
364
368
|
console.log(chalk.yellow('Note: "happy logout" is deprecated. Use "happy auth logout" instead.\n'));
|
|
365
369
|
try {
|
|
366
|
-
const { handleAuthCommand } = await import('./auth-
|
|
370
|
+
const { handleAuthCommand } = await import('./auth-DQH6q_q-.mjs');
|
|
367
371
|
await handleAuthCommand(["logout"]);
|
|
368
372
|
} catch (error) {
|
|
369
373
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -386,7 +390,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
386
390
|
return;
|
|
387
391
|
} else if (subcommand === "session") {
|
|
388
392
|
try {
|
|
389
|
-
const { handleSessionCommand } = await import('./session-
|
|
393
|
+
const { handleSessionCommand } = await import('./session-gfeFU8CA.mjs');
|
|
390
394
|
await handleSessionCommand(args.slice(1));
|
|
391
395
|
} catch (error) {
|
|
392
396
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -398,7 +402,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
398
402
|
return;
|
|
399
403
|
} else if (subcommand === "task") {
|
|
400
404
|
try {
|
|
401
|
-
const { handleTaskCommand } = await import('./task-
|
|
405
|
+
const { handleTaskCommand } = await import('./task-B-8_QGGX.mjs');
|
|
402
406
|
await handleTaskCommand(args.slice(1));
|
|
403
407
|
} catch (error) {
|
|
404
408
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -446,7 +450,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
446
450
|
return;
|
|
447
451
|
} else if (subcommand === "evidence") {
|
|
448
452
|
try {
|
|
449
|
-
const { handleEvidenceCommand } = await import('./evidence-
|
|
453
|
+
const { handleEvidenceCommand } = await import('./evidence-PUnN9yPK.mjs');
|
|
450
454
|
await handleEvidenceCommand(args.slice(1));
|
|
451
455
|
} catch (error) {
|
|
452
456
|
console.error(chalk.red("Error:"), error instanceof Error ? error.message : "Unknown error");
|
|
@@ -463,7 +467,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
463
467
|
process.exit(1);
|
|
464
468
|
}
|
|
465
469
|
try {
|
|
466
|
-
const { runMcpServe } = await import('./serve-
|
|
470
|
+
const { runMcpServe } = await import('./serve-BnlYj5ek.mjs');
|
|
467
471
|
await runMcpServe();
|
|
468
472
|
} catch (error) {
|
|
469
473
|
process.stderr.write(`[happy-mcp] fatal: ${error instanceof Error ? error.message : "unknown error"}
|
|
@@ -477,7 +481,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
477
481
|
console.error(chalk.red("Error:"), 'Not authenticated. Run "happy auth" first.');
|
|
478
482
|
process.exit(1);
|
|
479
483
|
}
|
|
480
|
-
const { parseSshArgs, runOnDevice, sshDevice, sshPickAndConnect } = await import('./ssh-
|
|
484
|
+
const { parseSshArgs, runOnDevice, sshDevice, sshPickAndConnect } = await import('./ssh-C-nEZiGP.mjs');
|
|
481
485
|
const { target, command, timeoutMs, stream } = parseSshArgs(args.slice(1));
|
|
482
486
|
try {
|
|
483
487
|
if (command) {
|
|
@@ -498,7 +502,7 @@ async function spawnAndWaitForDaemon() {
|
|
|
498
502
|
} else if (subcommand === "device") {
|
|
499
503
|
const deviceSubcommand = args[1];
|
|
500
504
|
if (deviceSubcommand === "push") {
|
|
501
|
-
const { pushToDevice } = await import('./push-
|
|
505
|
+
const { pushToDevice } = await import('./push-z5wQ4Ki_.mjs');
|
|
502
506
|
const credentials = await readCredentials();
|
|
503
507
|
if (!credentials) {
|
|
504
508
|
console.error(chalk.red("Error:"), 'Not authenticated. Run "happy auth" first.');
|
|
@@ -512,8 +516,8 @@ async function spawnAndWaitForDaemon() {
|
|
|
512
516
|
process.exit(await pushToDevice(credentials, target, localPath, remotePath));
|
|
513
517
|
}
|
|
514
518
|
if (deviceSubcommand === "enroll") {
|
|
515
|
-
const { enrollDevice } = await import('./enroll-
|
|
516
|
-
const { install } = await import('./install-
|
|
519
|
+
const { enrollDevice } = await import('./enroll-BlZ0giJI.mjs');
|
|
520
|
+
const { install } = await import('./install-BLPNuSeM.mjs');
|
|
517
521
|
const token = args[2];
|
|
518
522
|
if (!token) {
|
|
519
523
|
console.error(chalk.red("Error:"), "Missing enrollment token. Usage: happy device enroll <token>");
|
|
@@ -543,12 +547,12 @@ ${chalk.bold("Usage:")}
|
|
|
543
547
|
`);
|
|
544
548
|
process.exit(0);
|
|
545
549
|
} else if (subcommand === "daemon") {
|
|
546
|
-
const { startDaemon } = await import('./run-
|
|
547
|
-
const { install } = await import('./install-
|
|
548
|
-
const { uninstall } = await import('./uninstall-
|
|
549
|
-
const { runDoctorCommand } = await import('./doctor-
|
|
550
|
-
const { getLatestDaemonLog } = await import('./persistence-
|
|
551
|
-
const { listDaemonSessions, stopDaemonSession, stopDaemon } = await import('./controlClient-
|
|
550
|
+
const { startDaemon } = await import('./run-BFnSUK1o.mjs').then(function (n) { return n.r; });
|
|
551
|
+
const { install } = await import('./install-BLPNuSeM.mjs');
|
|
552
|
+
const { uninstall } = await import('./uninstall-CirMt_WC.mjs');
|
|
553
|
+
const { runDoctorCommand } = await import('./doctor-DDT2TXHH.mjs');
|
|
554
|
+
const { getLatestDaemonLog } = await import('./persistence-DbLMvLvk.mjs').then(function (n) { return n.E; });
|
|
555
|
+
const { listDaemonSessions, stopDaemonSession, stopDaemon } = await import('./controlClient-BzzTNSfl.mjs');
|
|
552
556
|
const daemonSubcommand = args[1];
|
|
553
557
|
if (daemonSubcommand === "list") {
|
|
554
558
|
try {
|
|
@@ -753,7 +757,7 @@ ${chalk.gray("\u2500".repeat(60))}
|
|
|
753
757
|
${chalk.bold.cyan("Claude Code Options (from `claude --help`):")}
|
|
754
758
|
`);
|
|
755
759
|
try {
|
|
756
|
-
const { claudeCliPath } = await import('./claudeLocal-
|
|
760
|
+
const { claudeCliPath } = await import('./claudeLocal-BXK_vQXS.mjs').then(function (n) { return n.d; });
|
|
757
761
|
const claudeHelp = execFileSync(claudeCliPath, ["--help"], { encoding: "utf8" });
|
|
758
762
|
console.log(claudeHelp);
|
|
759
763
|
} catch (e) {
|
|
@@ -783,10 +787,10 @@ ${chalk.bold.cyan("Claude Code Options (from `claude --help`):")}
|
|
|
783
787
|
}
|
|
784
788
|
process.exit(0);
|
|
785
789
|
}
|
|
786
|
-
const { authAndSetupMachineIfNeeded } = await import('./auth-
|
|
787
|
-
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await import('./controlClient-
|
|
788
|
-
const { spawnHappyCLI } = await import('./spawnHappyCLI-
|
|
789
|
-
const { runClaude } = await import('./runClaude-
|
|
790
|
+
const { authAndSetupMachineIfNeeded } = await import('./auth-qM2eojWx.mjs');
|
|
791
|
+
const { isDaemonRunningCurrentlyInstalledHappyVersion } = await import('./controlClient-BzzTNSfl.mjs');
|
|
792
|
+
const { spawnHappyCLI } = await import('./spawnHappyCLI-Dt7fbmbk.mjs').then(function (n) { return n.a; });
|
|
793
|
+
const { runClaude } = await import('./runClaude-CjENBdrX.mjs');
|
|
790
794
|
const {
|
|
791
795
|
credentials
|
|
792
796
|
} = await authAndSetupMachineIfNeeded();
|
|
@@ -860,7 +864,7 @@ ${chalk.bold("Examples:")}
|
|
|
860
864
|
}
|
|
861
865
|
console.log(chalk.blue("\u{1F4F1} Sending push notification..."));
|
|
862
866
|
try {
|
|
863
|
-
const { ApiClient } = await import('./api-
|
|
867
|
+
const { ApiClient } = await import('./api-BUCtd3cB.mjs').then(function (n) { return n.m; });
|
|
864
868
|
const api = await ApiClient.create(credentials);
|
|
865
869
|
const notificationTitle = title || "Happy AI";
|
|
866
870
|
api.push().sendToAllDevices(
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { l as logger, r as readCredentials } from './persistence-
|
|
2
|
-
import { i as install$2 } from './install-
|
|
1
|
+
import { l as logger, r as readCredentials } from './persistence-DbLMvLvk.mjs';
|
|
2
|
+
import { i as install$2 } from './install-BOIcR_Wr.mjs';
|
|
3
3
|
import { existsSync, mkdirSync, writeFileSync } from 'fs';
|
|
4
4
|
import { execSync } from 'child_process';
|
|
5
5
|
import path from 'path';
|
|
@@ -2,7 +2,7 @@ import { existsSync, mkdirSync, writeFileSync } from 'fs';
|
|
|
2
2
|
import { execSync } from 'child_process';
|
|
3
3
|
import os from 'os';
|
|
4
4
|
import { join } from 'path';
|
|
5
|
-
import { l as logger } from './persistence-
|
|
5
|
+
import { l as logger } from './persistence-DbLMvLvk.mjs';
|
|
6
6
|
import { t as trimIdent } from './trimIdent-BAjmv_TG.mjs';
|
|
7
7
|
import { p as projectPath } from './projectPath-BTBIMB57.mjs';
|
|
8
8
|
|
|
@@ -4,7 +4,7 @@ var fs = require('fs');
|
|
|
4
4
|
var child_process = require('child_process');
|
|
5
5
|
var os = require('os');
|
|
6
6
|
var path = require('path');
|
|
7
|
-
var logger = require('./persistence-
|
|
7
|
+
var logger = require('./persistence-D7zNFI-d.cjs');
|
|
8
8
|
var trimIdent = require('./trimIdent-4gvk9Wk6.cjs');
|
|
9
9
|
var projectPath = require('./projectPath-ChLhdOyt.cjs');
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var logger = require('./persistence-
|
|
4
|
-
var install$2 = require('./install-
|
|
3
|
+
var logger = require('./persistence-D7zNFI-d.cjs');
|
|
4
|
+
var install$2 = require('./install-Jrs6YUu8.cjs');
|
|
5
5
|
var fs = require('fs');
|
|
6
6
|
var child_process = require('child_process');
|
|
7
7
|
var path = require('path');
|
package/dist/lib.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var api = require('./api-
|
|
4
|
-
var logger = require('./persistence-
|
|
3
|
+
var api = require('./api-B-PlVQY6.cjs');
|
|
4
|
+
var logger = require('./persistence-D7zNFI-d.cjs');
|
|
5
5
|
var types = require('./types-DWeB7aqh.cjs');
|
|
6
6
|
require('axios');
|
|
7
7
|
require('node:events');
|
|
@@ -30,7 +30,7 @@ require('tweetnacl');
|
|
|
30
30
|
require('@stablelib/base64');
|
|
31
31
|
require('node:readline');
|
|
32
32
|
require('expo-server-sdk');
|
|
33
|
-
require('./sessionKeyCache-
|
|
33
|
+
require('./sessionKeyCache-3Pme04yL.cjs');
|
|
34
34
|
require('chalk');
|
|
35
35
|
require('fs');
|
|
36
36
|
|