clawmini 0.0.4 → 0.0.5
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/adapter-discord/index.mjs +1 -1
- package/dist/adapter-google-chat/index.mjs +1 -1
- package/dist/cli/index.mjs +2 -2
- package/dist/cli/lite.mjs +5 -3
- package/dist/cli/lite.mjs.map +1 -1
- package/dist/cli/propose-policy.mjs +2 -0
- package/dist/cli/propose-policy.mjs.map +1 -1
- package/dist/daemon/index.mjs +22 -6
- package/dist/daemon/index.mjs.map +1 -1
- package/dist/{lite-BbCFgEjn.mjs → lite-CBxOT1y5.mjs} +2 -2
- package/dist/{lite-BbCFgEjn.mjs.map → lite-CBxOT1y5.mjs.map} +1 -1
- package/{web/.svelte-kit/output/client/_app/immutable/chunks/ByezTNKv.js → dist/web/_app/immutable/chunks/C20lZMGz.js} +1 -1
- package/{web/.svelte-kit/output/client/_app/immutable/chunks/uD5YsQE1.js → dist/web/_app/immutable/chunks/C9lbZ-kT.js} +1 -1
- package/dist/web/_app/immutable/entry/{app.Dkba_ZYl.js → app.BgB5VkRU.js} +2 -2
- package/dist/web/_app/immutable/entry/start.DuxJo6av.js +1 -0
- package/dist/web/_app/immutable/nodes/{0.CFkkEWLe.js → 0.C9oFZP9h.js} +1 -1
- package/dist/web/_app/immutable/nodes/{1.BVylC0w0.js → 1.BON2Wk6k.js} +1 -1
- package/dist/web/_app/immutable/nodes/{3.DEhhZBsS.js → 3.CIs4tjjw.js} +1 -1
- package/dist/web/_app/immutable/nodes/{4.C_OhFIXf.js → 4.DLarELN4.js} +1 -1
- package/dist/web/_app/immutable/nodes/{5.Bj0bsDBW.js → 5.CE_QKy_3.js} +1 -1
- package/dist/web/_app/version.json +1 -1
- package/dist/web/index.html +6 -6
- package/dist/{workspace-CEdb2nPR.mjs → workspace-BJmJBfKi.mjs} +3 -1
- package/dist/workspace-BJmJBfKi.mjs.map +1 -0
- package/docs/23_custom_token_env/development_log.md +31 -0
- package/docs/23_custom_token_env/notes.md +16 -0
- package/docs/23_custom_token_env/prd.md +42 -0
- package/docs/23_custom_token_env/questions.md +8 -0
- package/docs/23_custom_token_env/tickets.md +54 -0
- package/napkin.md +1 -0
- package/package.json +1 -1
- package/src/adapter-google-chat/client.test.ts +1 -1
- package/src/cli/e2e/daemon.test.ts +103 -0
- package/src/cli/lite.ts +10 -3
- package/src/daemon/agent/agent-session.ts +20 -4
- package/src/shared/config.ts +2 -0
- package/templates/gemini/settings.json +23 -22
- package/templates/gemini-claw/settings.json +27 -26
- package/web/.svelte-kit/generated/server/internal.js +1 -1
- package/web/.svelte-kit/output/client/.vite/manifest.json +25 -25
- package/{dist/web/_app/immutable/chunks/ByezTNKv.js → web/.svelte-kit/output/client/_app/immutable/chunks/C20lZMGz.js} +1 -1
- package/{dist/web/_app/immutable/chunks/uD5YsQE1.js → web/.svelte-kit/output/client/_app/immutable/chunks/C9lbZ-kT.js} +1 -1
- package/web/.svelte-kit/output/client/_app/immutable/entry/{app.Dkba_ZYl.js → app.BgB5VkRU.js} +2 -2
- package/web/.svelte-kit/output/client/_app/immutable/entry/start.DuxJo6av.js +1 -0
- package/web/.svelte-kit/output/client/_app/immutable/nodes/{0.CFkkEWLe.js → 0.C9oFZP9h.js} +1 -1
- package/web/.svelte-kit/output/client/_app/immutable/nodes/{1.BVylC0w0.js → 1.BON2Wk6k.js} +1 -1
- package/web/.svelte-kit/output/client/_app/immutable/nodes/{3.DEhhZBsS.js → 3.CIs4tjjw.js} +1 -1
- package/web/.svelte-kit/output/client/_app/immutable/nodes/{4.C_OhFIXf.js → 4.DLarELN4.js} +1 -1
- package/web/.svelte-kit/output/client/_app/immutable/nodes/{5.Bj0bsDBW.js → 5.CE_QKy_3.js} +1 -1
- package/web/.svelte-kit/output/client/_app/version.json +1 -1
- package/web/.svelte-kit/output/server/chunks/internal.js +1 -1
- package/web/.svelte-kit/output/server/manifest-full.js +1 -1
- package/web/.svelte-kit/output/server/manifest.js +1 -1
- package/web/.svelte-kit/output/server/nodes/0.js +1 -1
- package/web/.svelte-kit/output/server/nodes/1.js +1 -1
- package/web/.svelte-kit/output/server/nodes/3.js +1 -1
- package/web/.svelte-kit/output/server/nodes/4.js +1 -1
- package/web/.svelte-kit/output/server/nodes/5.js +1 -1
- package/dist/web/_app/immutable/entry/start.B_seWfvF.js +0 -1
- package/dist/workspace-CEdb2nPR.mjs.map +0 -1
- package/web/.svelte-kit/output/client/_app/immutable/entry/start.B_seWfvF.js +0 -1
package/dist/daemon/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as writeAgentSessionSettings, D as pathIsInsideDir, O as CronJobSchema, S as updateChatSettings, T as writeChatSettings, _ as readEnvironment, b as resolveAgentWorkDir, c as getClawminiDir, d as getSocketPath, f as getWorkspaceRoot, g as readChatSettings, h as readAgentSessionSettings, k as SettingsSchema, l as getEnvironmentPath, m as listAgents, o as getActiveEnvironmentInfo, s as getAgent, u as getSettingsPath, v as readPolicies, y as readSettings } from "../workspace-
|
|
2
|
-
import { c as createChat, f as getDefaultChatId, h as listChats, n as exportLiteToEnvironment, p as getMessages$1, s as appendMessage$1, u as findLastMessage } from "../lite-
|
|
1
|
+
import { C as writeAgentSessionSettings, D as pathIsInsideDir, O as CronJobSchema, S as updateChatSettings, T as writeChatSettings, _ as readEnvironment, b as resolveAgentWorkDir, c as getClawminiDir, d as getSocketPath, f as getWorkspaceRoot, g as readChatSettings, h as readAgentSessionSettings, k as SettingsSchema, l as getEnvironmentPath, m as listAgents, o as getActiveEnvironmentInfo, s as getAgent, u as getSettingsPath, v as readPolicies, y as readSettings } from "../workspace-BJmJBfKi.mjs";
|
|
2
|
+
import { c as createChat, f as getDefaultChatId, h as listChats, n as exportLiteToEnvironment, p as getMessages$1, s as appendMessage$1, u as findLastMessage } from "../lite-CBxOT1y5.mjs";
|
|
3
3
|
import fs, { constants } from "node:fs";
|
|
4
4
|
import path from "node:path";
|
|
5
5
|
import { execSync, spawn } from "node:child_process";
|
|
@@ -1289,16 +1289,32 @@ var AgentSession = class {
|
|
|
1289
1289
|
Object.keys(routerEnv).forEach((k) => agentSpecificEnvKeys.add(k));
|
|
1290
1290
|
const apiCtx = getApiContext(this.globalSettings);
|
|
1291
1291
|
if (apiCtx) {
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1292
|
+
const proxyUrl = apiCtx.proxy_host ? `${apiCtx.proxy_host}:${apiCtx.port}` : `http://${apiCtx.host}:${apiCtx.port}`;
|
|
1293
|
+
if (currentAgent.apiUrlEnvVar) {
|
|
1294
|
+
env[currentAgent.apiUrlEnvVar] = proxyUrl;
|
|
1295
|
+
agentSpecificEnvKeys.add(currentAgent.apiUrlEnvVar);
|
|
1296
|
+
env["CLAW_LITE_URL_VAR"] = currentAgent.apiUrlEnvVar;
|
|
1297
|
+
agentSpecificEnvKeys.add("CLAW_LITE_URL_VAR");
|
|
1298
|
+
} else {
|
|
1299
|
+
env["CLAW_API_URL"] = proxyUrl;
|
|
1300
|
+
agentSpecificEnvKeys.add("CLAW_API_URL");
|
|
1301
|
+
}
|
|
1302
|
+
const token = generateToken({
|
|
1295
1303
|
chatId: this.chatId,
|
|
1296
1304
|
agentId: this.agentId,
|
|
1297
1305
|
sessionId: this.sessionId,
|
|
1298
1306
|
...this.subagentId ? { subagentId: this.subagentId } : {},
|
|
1299
1307
|
timestamp: Date.now()
|
|
1300
1308
|
});
|
|
1301
|
-
|
|
1309
|
+
if (currentAgent.apiTokenEnvVar) {
|
|
1310
|
+
env[currentAgent.apiTokenEnvVar] = token;
|
|
1311
|
+
agentSpecificEnvKeys.add(currentAgent.apiTokenEnvVar);
|
|
1312
|
+
env["CLAW_LITE_API_VAR"] = currentAgent.apiTokenEnvVar;
|
|
1313
|
+
agentSpecificEnvKeys.add("CLAW_LITE_API_VAR");
|
|
1314
|
+
} else {
|
|
1315
|
+
env["CLAW_API_TOKEN"] = token;
|
|
1316
|
+
agentSpecificEnvKeys.add("CLAW_API_TOKEN");
|
|
1317
|
+
}
|
|
1302
1318
|
}
|
|
1303
1319
|
let command = initialCommand;
|
|
1304
1320
|
command = await sandboxExecutionContext(command, env, agentSpecificEnvKeys, this.workDirectory, this.workspaceRoot);
|