@episoda/cli 0.2.200 → 0.2.202
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/daemon/daemon-process.js +22 -5
- package/dist/daemon/daemon-process.js.map +1 -1
- package/dist/index.js +22 -5
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -3046,7 +3046,7 @@ var require_package = __commonJS({
|
|
|
3046
3046
|
"package.json"(exports2, module2) {
|
|
3047
3047
|
module2.exports = {
|
|
3048
3048
|
name: "@episoda/cli",
|
|
3049
|
-
version: "0.2.
|
|
3049
|
+
version: "0.2.202",
|
|
3050
3050
|
description: "CLI tool for Episoda local development workflow orchestration",
|
|
3051
3051
|
main: "dist/index.js",
|
|
3052
3052
|
types: "dist/index.d.ts",
|
|
@@ -6653,6 +6653,7 @@ async function ensureCodexBinary() {
|
|
|
6653
6653
|
}
|
|
6654
6654
|
|
|
6655
6655
|
// src/agent/providers/codex-config.ts
|
|
6656
|
+
var DEFAULT_CODEX_MODEL = "gpt-5.4-codex-high";
|
|
6656
6657
|
function generateCodexAuthJson(credentials) {
|
|
6657
6658
|
if (!credentials.refreshToken) {
|
|
6658
6659
|
throw new Error(
|
|
@@ -6679,7 +6680,9 @@ function generateCodexAuthJson(credentials) {
|
|
|
6679
6680
|
}
|
|
6680
6681
|
function generateCodexConfigToml(projectPath) {
|
|
6681
6682
|
const escapedPath = projectPath.replace(/\\/g, "\\\\").replace(/"/g, '\\"');
|
|
6682
|
-
return `
|
|
6683
|
+
return `model = "${DEFAULT_CODEX_MODEL}"
|
|
6684
|
+
|
|
6685
|
+
[projects."${escapedPath}"]
|
|
6683
6686
|
trust_level = "trusted"
|
|
6684
6687
|
`;
|
|
6685
6688
|
}
|
|
@@ -6696,7 +6699,7 @@ function escapeTomlString(value) {
|
|
|
6696
6699
|
return value.replace(/\\/g, "\\\\").replace(/"/g, '\\"').replace(/\n/g, "\\n").replace(/\r/g, "\\r").replace(/\t/g, "\\t");
|
|
6697
6700
|
}
|
|
6698
6701
|
function generateCodexMcpConfigToml(servers, projectPath) {
|
|
6699
|
-
const lines = [];
|
|
6702
|
+
const lines = [`model = "${DEFAULT_CODEX_MODEL}"`, ""];
|
|
6700
6703
|
if (projectPath) {
|
|
6701
6704
|
const escapedPath = escapeTomlString(projectPath);
|
|
6702
6705
|
lines.push(`[projects."${escapedPath}"]`);
|
|
@@ -9032,6 +9035,7 @@ var CodexProvider = class {
|
|
|
9032
9035
|
args.push("--sandbox", "read-only");
|
|
9033
9036
|
console.log("[CodexProvider] EP1205: Codex read-only mode - using --sandbox read-only");
|
|
9034
9037
|
}
|
|
9038
|
+
args.push("--model", session.credentials.preferredModel || DEFAULT_CODEX_MODEL);
|
|
9035
9039
|
if (resumeSessionId) {
|
|
9036
9040
|
args.push("resume", resumeSessionId);
|
|
9037
9041
|
}
|
|
@@ -16460,6 +16464,9 @@ async function configureGitUser(projectPath, userId, workspaceId, machineId, pro
|
|
|
16460
16464
|
const { execSync: execSync19 } = await import("child_process");
|
|
16461
16465
|
const { gitDir, workDir } = getGitDirs(projectPath);
|
|
16462
16466
|
const gitCmd = gitDir ? `git --git-dir="${gitDir}"` : "git";
|
|
16467
|
+
const gitEmailDomain = process.env.EPISODA_AGENT_GIT_EMAIL_DOMAIN || "users.episoda.dev";
|
|
16468
|
+
const gitIdentityName = `Episoda ${userId}`;
|
|
16469
|
+
const gitIdentityEmail = `${userId}@${gitEmailDomain}`;
|
|
16463
16470
|
execSync19(`${gitCmd} config episoda.userId ${userId}`, {
|
|
16464
16471
|
cwd: workDir,
|
|
16465
16472
|
encoding: "utf8",
|
|
@@ -16487,7 +16494,17 @@ async function configureGitUser(projectPath, userId, workspaceId, machineId, pro
|
|
|
16487
16494
|
stdio: "pipe"
|
|
16488
16495
|
});
|
|
16489
16496
|
}
|
|
16490
|
-
|
|
16497
|
+
execSync19(`${gitCmd} config user.name "${gitIdentityName.replace(/"/g, '\\"')}"`, {
|
|
16498
|
+
cwd: workDir,
|
|
16499
|
+
encoding: "utf8",
|
|
16500
|
+
stdio: "pipe"
|
|
16501
|
+
});
|
|
16502
|
+
execSync19(`${gitCmd} config user.email ${gitIdentityEmail}`, {
|
|
16503
|
+
cwd: workDir,
|
|
16504
|
+
encoding: "utf8",
|
|
16505
|
+
stdio: "pipe"
|
|
16506
|
+
});
|
|
16507
|
+
console.log(`[Daemon] Configured git for project: episoda.userId=${userId}, machineId=${machineId}, projectId=${projectId}, gitIdentity=${gitIdentityEmail}${machineUuid ? `, machineUuid=${machineUuid}` : ""}`);
|
|
16491
16508
|
} catch (error) {
|
|
16492
16509
|
console.warn(`[Daemon] Failed to configure git user for ${projectPath}:`, error instanceof Error ? error.message : error);
|
|
16493
16510
|
}
|
|
@@ -17562,7 +17579,7 @@ var Daemon = class _Daemon {
|
|
|
17562
17579
|
const modeConfig = getDaemonModeConfig();
|
|
17563
17580
|
const environment = modeConfig.mode;
|
|
17564
17581
|
const containerId = process.env.EPISODA_CONTAINER_ID;
|
|
17565
|
-
const capabilities = ["worktree_create_v1"];
|
|
17582
|
+
const capabilities = ["worktree_create_v1", "pty_v1"];
|
|
17566
17583
|
await client.connect(wsEndpoint.wsUrl, config.access_token, this.machineId, {
|
|
17567
17584
|
hostname: os17.hostname(),
|
|
17568
17585
|
osPlatform: os17.platform(),
|