@askexenow/exe-os 0.8.65 → 0.8.69
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/bin/cleanup-stale-review-tasks.js +8 -7
- package/dist/bin/cli.js +204 -120
- package/dist/bin/exe-assign.js +11 -10
- package/dist/bin/exe-boot.js +83 -78
- package/dist/bin/exe-call.js +33 -1
- package/dist/bin/exe-cloud.js +3 -2
- package/dist/bin/exe-dispatch.js +31 -30
- package/dist/bin/exe-gateway.js +33 -32
- package/dist/bin/exe-heartbeat.js +21 -20
- package/dist/bin/exe-launch-agent.js +84 -19
- package/dist/bin/exe-link.js +16 -11
- package/dist/bin/exe-new-employee.js +20 -19
- package/dist/bin/exe-pending-messages.js +7 -6
- package/dist/bin/exe-pending-reviews.js +16 -15
- package/dist/bin/exe-rename.js +12 -11
- package/dist/bin/exe-review.js +4 -3
- package/dist/bin/exe-session-cleanup.js +20 -19
- package/dist/bin/exe-settings.js +3 -2
- package/dist/bin/exe-status.js +16 -15
- package/dist/bin/exe-team.js +4 -3
- package/dist/bin/git-sweep.js +31 -30
- package/dist/bin/install.js +284 -113
- package/dist/bin/scan-tasks.js +33 -32
- package/dist/bin/setup.js +114 -30
- package/dist/gateway/index.js +32 -31
- package/dist/hooks/bug-report-worker.js +58 -26
- package/dist/hooks/commit-complete.js +31 -30
- package/dist/hooks/ingest-worker.js +58 -57
- package/dist/hooks/post-compact.js +10 -9
- package/dist/hooks/pre-compact.js +31 -30
- package/dist/hooks/pre-tool-use.js +46 -14
- package/dist/hooks/prompt-ingest-worker.js +15 -14
- package/dist/hooks/prompt-submit.js +15 -14
- package/dist/hooks/response-ingest-worker.js +8 -7
- package/dist/hooks/session-end.js +14 -13
- package/dist/hooks/session-start.js +10 -9
- package/dist/hooks/stop.js +10 -9
- package/dist/hooks/subagent-stop.js +10 -9
- package/dist/hooks/summary-worker.js +41 -36
- package/dist/index.js +43 -42
- package/dist/lib/cloud-sync.js +16 -11
- package/dist/lib/employees.js +33 -1
- package/dist/lib/exe-daemon.js +56 -55
- package/dist/lib/messaging.js +9 -8
- package/dist/lib/tasks.js +27 -26
- package/dist/lib/tmux-routing.js +29 -28
- package/dist/mcp/server.js +94 -62
- package/dist/mcp/tools/create-task.js +60 -28
- package/dist/mcp/tools/list-tasks.js +10 -9
- package/dist/mcp/tools/send-message.js +11 -10
- package/dist/mcp/tools/update-task.js +21 -20
- package/dist/runtime/index.js +31 -30
- package/dist/tui/App.js +67 -35
- package/package.json +1 -1
package/dist/bin/git-sweep.js
CHANGED
|
@@ -1438,9 +1438,10 @@ var init_config = __esm({
|
|
|
1438
1438
|
|
|
1439
1439
|
// src/lib/employees.ts
|
|
1440
1440
|
import { readFile as readFile2, writeFile as writeFile2, mkdir as mkdir2 } from "fs/promises";
|
|
1441
|
-
import { existsSync as existsSync4, symlinkSync, readlinkSync, readFileSync as readFileSync4 } from "fs";
|
|
1441
|
+
import { existsSync as existsSync4, symlinkSync, readlinkSync, readFileSync as readFileSync4, renameSync as renameSync3, unlinkSync, writeFileSync as writeFileSync3 } from "fs";
|
|
1442
1442
|
import { execSync as execSync3 } from "child_process";
|
|
1443
1443
|
import path4 from "path";
|
|
1444
|
+
import os4 from "os";
|
|
1444
1445
|
function loadEmployeesSync(employeesPath = EMPLOYEES_PATH) {
|
|
1445
1446
|
if (!existsSync4(employeesPath)) return [];
|
|
1446
1447
|
try {
|
|
@@ -1469,7 +1470,7 @@ var init_employees = __esm({
|
|
|
1469
1470
|
});
|
|
1470
1471
|
|
|
1471
1472
|
// src/lib/license.ts
|
|
1472
|
-
import { readFileSync as readFileSync5, writeFileSync as
|
|
1473
|
+
import { readFileSync as readFileSync5, writeFileSync as writeFileSync4, existsSync as existsSync5, mkdirSync as mkdirSync3 } from "fs";
|
|
1473
1474
|
import { randomUUID } from "crypto";
|
|
1474
1475
|
import path5 from "path";
|
|
1475
1476
|
import { jwtVerify, importSPKI } from "jose";
|
|
@@ -1572,11 +1573,11 @@ var init_plan_limits = __esm({
|
|
|
1572
1573
|
// src/lib/notifications.ts
|
|
1573
1574
|
import crypto from "crypto";
|
|
1574
1575
|
import path7 from "path";
|
|
1575
|
-
import
|
|
1576
|
+
import os5 from "os";
|
|
1576
1577
|
import {
|
|
1577
1578
|
readFileSync as readFileSync7,
|
|
1578
1579
|
readdirSync,
|
|
1579
|
-
unlinkSync,
|
|
1580
|
+
unlinkSync as unlinkSync2,
|
|
1580
1581
|
existsSync as existsSync7,
|
|
1581
1582
|
rmdirSync
|
|
1582
1583
|
} from "fs";
|
|
@@ -2143,7 +2144,7 @@ var init_tasks_crud = __esm({
|
|
|
2143
2144
|
|
|
2144
2145
|
// src/lib/tasks-review.ts
|
|
2145
2146
|
import path9 from "path";
|
|
2146
|
-
import { existsSync as existsSync9, readdirSync as readdirSync2, unlinkSync as
|
|
2147
|
+
import { existsSync as existsSync9, readdirSync as readdirSync2, unlinkSync as unlinkSync3 } from "fs";
|
|
2147
2148
|
async function countPendingReviews(sessionScope) {
|
|
2148
2149
|
const client = getClient();
|
|
2149
2150
|
if (sessionScope) {
|
|
@@ -2328,7 +2329,7 @@ async function cleanupReviewFile(row, taskFile, _baseDir) {
|
|
|
2328
2329
|
if (existsSync9(cacheDir)) {
|
|
2329
2330
|
for (const f of readdirSync2(cacheDir)) {
|
|
2330
2331
|
if (f.startsWith("review-notified-")) {
|
|
2331
|
-
|
|
2332
|
+
unlinkSync3(path9.join(cacheDir, f));
|
|
2332
2333
|
}
|
|
2333
2334
|
}
|
|
2334
2335
|
}
|
|
@@ -2934,7 +2935,7 @@ __export(tasks_exports, {
|
|
|
2934
2935
|
writeCheckpoint: () => writeCheckpoint
|
|
2935
2936
|
});
|
|
2936
2937
|
import path12 from "path";
|
|
2937
|
-
import { writeFileSync as
|
|
2938
|
+
import { writeFileSync as writeFileSync5, mkdirSync as mkdirSync4, unlinkSync as unlinkSync4 } from "fs";
|
|
2938
2939
|
async function createTask(input) {
|
|
2939
2940
|
const result = await createTaskCore(input);
|
|
2940
2941
|
if (!input.skipDispatch && result.status !== "blocked" && !process.env.VITEST) {
|
|
@@ -2957,10 +2958,10 @@ async function updateTask(input) {
|
|
|
2957
2958
|
const cachePath = path12.join(cacheDir, `current-task-${agent}.json`);
|
|
2958
2959
|
if (input.status === "in_progress") {
|
|
2959
2960
|
mkdirSync4(cacheDir, { recursive: true });
|
|
2960
|
-
|
|
2961
|
+
writeFileSync5(cachePath, JSON.stringify({ taskId, title: String(row.title) }));
|
|
2961
2962
|
} else if (input.status === "done" || input.status === "blocked" || input.status === "cancelled") {
|
|
2962
2963
|
try {
|
|
2963
|
-
|
|
2964
|
+
unlinkSync4(cachePath);
|
|
2964
2965
|
} catch {
|
|
2965
2966
|
}
|
|
2966
2967
|
}
|
|
@@ -3402,11 +3403,11 @@ __export(tmux_routing_exports, {
|
|
|
3402
3403
|
verifyPaneAtCapacity: () => verifyPaneAtCapacity
|
|
3403
3404
|
});
|
|
3404
3405
|
import { execFileSync as execFileSync2, execSync as execSync6 } from "child_process";
|
|
3405
|
-
import { readFileSync as readFileSync9, writeFileSync as
|
|
3406
|
+
import { readFileSync as readFileSync9, writeFileSync as writeFileSync6, mkdirSync as mkdirSync5, existsSync as existsSync10, appendFileSync } from "fs";
|
|
3406
3407
|
import path13 from "path";
|
|
3407
|
-
import
|
|
3408
|
+
import os6 from "os";
|
|
3408
3409
|
import { fileURLToPath } from "url";
|
|
3409
|
-
import { unlinkSync as
|
|
3410
|
+
import { unlinkSync as unlinkSync5 } from "fs";
|
|
3410
3411
|
function spawnLockPath(sessionName) {
|
|
3411
3412
|
return path13.join(SPAWN_LOCK_DIR, `${sessionName}.lock`);
|
|
3412
3413
|
}
|
|
@@ -3433,12 +3434,12 @@ function acquireSpawnLock(sessionName) {
|
|
|
3433
3434
|
} catch {
|
|
3434
3435
|
}
|
|
3435
3436
|
}
|
|
3436
|
-
|
|
3437
|
+
writeFileSync6(lockFile, JSON.stringify({ pid: process.pid, timestamp: Date.now() }));
|
|
3437
3438
|
return true;
|
|
3438
3439
|
}
|
|
3439
3440
|
function releaseSpawnLock(sessionName) {
|
|
3440
3441
|
try {
|
|
3441
|
-
|
|
3442
|
+
unlinkSync5(spawnLockPath(sessionName));
|
|
3442
3443
|
} catch {
|
|
3443
3444
|
}
|
|
3444
3445
|
}
|
|
@@ -3520,7 +3521,7 @@ function registerParentExe(sessionKey, parentExe, dispatchedBy) {
|
|
|
3520
3521
|
}
|
|
3521
3522
|
const rootExe = extractRootExe(parentExe) ?? parentExe;
|
|
3522
3523
|
const filePath = path13.join(SESSION_CACHE, `parent-exe-${sessionKey}.json`);
|
|
3523
|
-
|
|
3524
|
+
writeFileSync6(filePath, JSON.stringify({
|
|
3524
3525
|
parentExe: rootExe,
|
|
3525
3526
|
dispatchedBy: dispatchedBy || rootExe,
|
|
3526
3527
|
registeredAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
@@ -3607,7 +3608,7 @@ function readDebounceState() {
|
|
|
3607
3608
|
function writeDebounceState(state) {
|
|
3608
3609
|
try {
|
|
3609
3610
|
if (!existsSync10(SESSION_CACHE)) mkdirSync5(SESSION_CACHE, { recursive: true });
|
|
3610
|
-
|
|
3611
|
+
writeFileSync6(DEBOUNCE_FILE, JSON.stringify(state));
|
|
3611
3612
|
} catch {
|
|
3612
3613
|
}
|
|
3613
3614
|
}
|
|
@@ -3796,7 +3797,7 @@ function spawnEmployee(employeeName, exeSession, projectDir, opts) {
|
|
|
3796
3797
|
const transport = getTransport();
|
|
3797
3798
|
const sessionName = employeeSessionName(employeeName, exeSession, opts?.instance);
|
|
3798
3799
|
const instanceLabel = opts?.instance != null && opts.instance > 0 ? `${employeeName}${opts.instance}` : employeeName;
|
|
3799
|
-
const logDir = path13.join(
|
|
3800
|
+
const logDir = path13.join(os6.homedir(), ".exe-os", "session-logs");
|
|
3800
3801
|
const logFile = path13.join(logDir, `${instanceLabel}-${Date.now()}.log`);
|
|
3801
3802
|
if (!existsSync10(logDir)) {
|
|
3802
3803
|
mkdirSync5(logDir, { recursive: true });
|
|
@@ -3812,7 +3813,7 @@ function spawnEmployee(employeeName, exeSession, projectDir, opts) {
|
|
|
3812
3813
|
} catch {
|
|
3813
3814
|
}
|
|
3814
3815
|
try {
|
|
3815
|
-
const claudeJsonPath = path13.join(
|
|
3816
|
+
const claudeJsonPath = path13.join(os6.homedir(), ".claude.json");
|
|
3816
3817
|
let claudeJson = {};
|
|
3817
3818
|
try {
|
|
3818
3819
|
claudeJson = JSON.parse(readFileSync9(claudeJsonPath, "utf8"));
|
|
@@ -3823,11 +3824,11 @@ function spawnEmployee(employeeName, exeSession, projectDir, opts) {
|
|
|
3823
3824
|
const trustDir = opts?.cwd ?? projectDir;
|
|
3824
3825
|
if (!projects[trustDir]) projects[trustDir] = {};
|
|
3825
3826
|
projects[trustDir].hasTrustDialogAccepted = true;
|
|
3826
|
-
|
|
3827
|
+
writeFileSync6(claudeJsonPath, JSON.stringify(claudeJson, null, 2) + "\n");
|
|
3827
3828
|
} catch {
|
|
3828
3829
|
}
|
|
3829
3830
|
try {
|
|
3830
|
-
const settingsDir = path13.join(
|
|
3831
|
+
const settingsDir = path13.join(os6.homedir(), ".claude", "projects");
|
|
3831
3832
|
const normalizedKey = (opts?.cwd ?? projectDir).replace(/\//g, "-").replace(/^-/, "");
|
|
3832
3833
|
const projSettingsDir = path13.join(settingsDir, normalizedKey);
|
|
3833
3834
|
const settingsPath = path13.join(projSettingsDir, "settings.json");
|
|
@@ -3862,7 +3863,7 @@ function spawnEmployee(employeeName, exeSession, projectDir, opts) {
|
|
|
3862
3863
|
perms.allow = allow;
|
|
3863
3864
|
settings.permissions = perms;
|
|
3864
3865
|
mkdirSync5(projSettingsDir, { recursive: true });
|
|
3865
|
-
|
|
3866
|
+
writeFileSync6(settingsPath, JSON.stringify(settings, null, 2) + "\n");
|
|
3866
3867
|
}
|
|
3867
3868
|
} catch {
|
|
3868
3869
|
}
|
|
@@ -3875,7 +3876,7 @@ function spawnEmployee(employeeName, exeSession, projectDir, opts) {
|
|
|
3875
3876
|
let legacyFallbackWarned = false;
|
|
3876
3877
|
if (!useExeAgent && !useBinSymlink) {
|
|
3877
3878
|
const identityPath = path13.join(
|
|
3878
|
-
|
|
3879
|
+
os6.homedir(),
|
|
3879
3880
|
".exe-os",
|
|
3880
3881
|
"identity",
|
|
3881
3882
|
`${employeeName}.md`
|
|
@@ -3905,7 +3906,7 @@ function spawnEmployee(employeeName, exeSession, projectDir, opts) {
|
|
|
3905
3906
|
}
|
|
3906
3907
|
let sessionContextFlag = "";
|
|
3907
3908
|
try {
|
|
3908
|
-
const ctxDir = path13.join(
|
|
3909
|
+
const ctxDir = path13.join(os6.homedir(), ".exe-os", "session-cache");
|
|
3909
3910
|
mkdirSync5(ctxDir, { recursive: true });
|
|
3910
3911
|
const ctxFile = path13.join(ctxDir, `session-context-${sessionName}.md`);
|
|
3911
3912
|
const ctxContent = [
|
|
@@ -3914,7 +3915,7 @@ function spawnEmployee(employeeName, exeSession, projectDir, opts) {
|
|
|
3914
3915
|
`Your parent exe session is ${exeSession}.`,
|
|
3915
3916
|
`Your employees (if any) use the -${exeSession} suffix (e.g., tom-${exeSession}).`
|
|
3916
3917
|
].join("\n");
|
|
3917
|
-
|
|
3918
|
+
writeFileSync6(ctxFile, ctxContent);
|
|
3918
3919
|
sessionContextFlag = ` --append-system-prompt-file ${ctxFile}`;
|
|
3919
3920
|
} catch {
|
|
3920
3921
|
}
|
|
@@ -3953,7 +3954,7 @@ function spawnEmployee(employeeName, exeSession, projectDir, opts) {
|
|
|
3953
3954
|
try {
|
|
3954
3955
|
const mySession = getMySession();
|
|
3955
3956
|
const dispatchInfo = path13.join(SESSION_CACHE, `dispatch-info-${sessionName}.json`);
|
|
3956
|
-
|
|
3957
|
+
writeFileSync6(dispatchInfo, JSON.stringify({
|
|
3957
3958
|
dispatchedBy: mySession,
|
|
3958
3959
|
rootExe: exeSession,
|
|
3959
3960
|
provider: useBinSymlink ? ccProvider : useExeAgent ? opts.provider : "anthropic",
|
|
@@ -4016,13 +4017,13 @@ var init_tmux_routing = __esm({
|
|
|
4016
4017
|
init_provider_table();
|
|
4017
4018
|
init_intercom_queue();
|
|
4018
4019
|
init_plan_limits();
|
|
4019
|
-
SPAWN_LOCK_DIR = path13.join(
|
|
4020
|
-
SESSION_CACHE = path13.join(
|
|
4020
|
+
SPAWN_LOCK_DIR = path13.join(os6.homedir(), ".exe-os", "spawn-locks");
|
|
4021
|
+
SESSION_CACHE = path13.join(os6.homedir(), ".exe-os", "session-cache");
|
|
4021
4022
|
BEHAVIORS_EXPORT_TIMEOUT_MS = 1e4;
|
|
4022
4023
|
VALID_SESSION_NAME = /^[a-z]+\d*-[a-zA-Z0-9_]+$/;
|
|
4023
4024
|
VERIFY_PANE_LINES = 200;
|
|
4024
4025
|
INTERCOM_DEBOUNCE_MS = 3e4;
|
|
4025
|
-
INTERCOM_LOG2 = path13.join(
|
|
4026
|
+
INTERCOM_LOG2 = path13.join(os6.homedir(), ".exe-os", "intercom.log");
|
|
4026
4027
|
DEBOUNCE_FILE = path13.join(SESSION_CACHE, "intercom-debounce.json");
|
|
4027
4028
|
DEBOUNCE_CLEANUP_AGE_MS = 5 * 60 * 1e3;
|
|
4028
4029
|
BUSY_PATTERN = /[✻✽✶✳·].*…|Running…/;
|
|
@@ -4066,9 +4067,9 @@ var init_memory = __esm({
|
|
|
4066
4067
|
import { readFile as readFile4, writeFile as writeFile5, unlink, mkdir as mkdir4, chmod as chmod2 } from "fs/promises";
|
|
4067
4068
|
import { existsSync as existsSync11 } from "fs";
|
|
4068
4069
|
import path14 from "path";
|
|
4069
|
-
import
|
|
4070
|
+
import os7 from "os";
|
|
4070
4071
|
function getKeyDir() {
|
|
4071
|
-
return process.env.EXE_OS_DIR ?? process.env.EXE_MEM_DIR ?? path14.join(
|
|
4072
|
+
return process.env.EXE_OS_DIR ?? process.env.EXE_MEM_DIR ?? path14.join(os7.homedir(), ".exe-os");
|
|
4072
4073
|
}
|
|
4073
4074
|
function getKeyPath() {
|
|
4074
4075
|
return path14.join(getKeyDir(), "master.key");
|