@cleocode/cleo 2026.3.63 → 2026.3.65
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/cli/commands/add.d.ts.map +1 -1
- package/dist/cli/commands/add.js +5 -2
- package/dist/cli/commands/add.js.map +1 -1
- package/dist/cli/commands/agents.d.ts +31 -0
- package/dist/cli/commands/agents.d.ts.map +1 -0
- package/dist/cli/commands/agents.js +104 -0
- package/dist/cli/commands/agents.js.map +1 -0
- package/dist/cli/commands/backfill.d.ts +32 -0
- package/dist/cli/commands/backfill.d.ts.map +1 -0
- package/dist/cli/commands/backfill.js +101 -0
- package/dist/cli/commands/backfill.js.map +1 -0
- package/dist/cli/commands/backup.js +1 -1
- package/dist/cli/commands/backup.js.map +1 -1
- package/dist/cli/commands/config.d.ts +1 -0
- package/dist/cli/commands/config.d.ts.map +1 -1
- package/dist/cli/commands/config.js +26 -0
- package/dist/cli/commands/config.js.map +1 -1
- package/dist/cli/commands/context.js +1 -1
- package/dist/cli/commands/context.js.map +1 -1
- package/dist/cli/commands/deps.d.ts +15 -0
- package/dist/cli/commands/deps.d.ts.map +1 -1
- package/dist/cli/commands/deps.js +28 -3
- package/dist/cli/commands/deps.js.map +1 -1
- package/dist/cli/commands/detect-drift.d.ts.map +1 -1
- package/dist/cli/commands/detect-drift.js +4 -3
- package/dist/cli/commands/detect-drift.js.map +1 -1
- package/dist/cli/commands/exists.d.ts +15 -0
- package/dist/cli/commands/exists.d.ts.map +1 -1
- package/dist/cli/commands/exists.js +33 -15
- package/dist/cli/commands/exists.js.map +1 -1
- package/dist/cli/commands/issue.d.ts +3 -0
- package/dist/cli/commands/issue.d.ts.map +1 -1
- package/dist/cli/commands/issue.js +23 -21
- package/dist/cli/commands/issue.js.map +1 -1
- package/dist/cli/commands/labels.js +1 -1
- package/dist/cli/commands/labels.js.map +1 -1
- package/dist/cli/commands/phases.js +1 -1
- package/dist/cli/commands/phases.js.map +1 -1
- package/dist/cli/commands/reason.d.ts +35 -0
- package/dist/cli/commands/reason.d.ts.map +1 -0
- package/dist/cli/commands/reason.js +104 -0
- package/dist/cli/commands/reason.js.map +1 -0
- package/dist/cli/commands/session.d.ts.map +1 -1
- package/dist/cli/commands/session.js +15 -0
- package/dist/cli/commands/session.js.map +1 -1
- package/dist/cli/commands/stats.d.ts.map +1 -1
- package/dist/cli/commands/stats.js +13 -1
- package/dist/cli/commands/stats.js.map +1 -1
- package/dist/cli/commands/update.d.ts.map +1 -1
- package/dist/cli/commands/update.js +8 -2
- package/dist/cli/commands/update.js.map +1 -1
- package/dist/cli/index.js +48 -9
- package/dist/cli/index.js.map +3 -3
- package/dist/dispatch/domains/admin.d.ts.map +1 -1
- package/dist/dispatch/domains/admin.js +25 -1
- package/dist/dispatch/domains/admin.js.map +1 -1
- package/dist/dispatch/domains/check.d.ts.map +1 -1
- package/dist/dispatch/domains/check.js +15 -1
- package/dist/dispatch/domains/check.js.map +1 -1
- package/dist/dispatch/domains/tasks.d.ts.map +1 -1
- package/dist/dispatch/domains/tasks.js +17 -1
- package/dist/dispatch/domains/tasks.js.map +1 -1
- package/dist/dispatch/engines/config-engine.d.ts +11 -0
- package/dist/dispatch/engines/config-engine.d.ts.map +1 -1
- package/dist/dispatch/engines/config-engine.js +26 -1
- package/dist/dispatch/engines/config-engine.js.map +1 -1
- package/dist/dispatch/engines/session-engine.d.ts.map +1 -1
- package/dist/dispatch/engines/session-engine.js +9 -5
- package/dist/dispatch/engines/session-engine.js.map +1 -1
- package/dist/dispatch/engines/system-engine.d.ts +6 -1
- package/dist/dispatch/engines/system-engine.d.ts.map +1 -1
- package/dist/dispatch/engines/system-engine.js +14 -1
- package/dist/dispatch/engines/system-engine.js.map +1 -1
- package/dist/dispatch/engines/task-engine.d.ts +19 -1
- package/dist/dispatch/engines/task-engine.d.ts.map +1 -1
- package/dist/dispatch/engines/task-engine.js +31 -2
- package/dist/dispatch/engines/task-engine.js.map +1 -1
- package/dist/dispatch/lib/engine.d.ts +3 -3
- package/dist/dispatch/lib/engine.d.ts.map +1 -1
- package/dist/dispatch/lib/engine.js +3 -3
- package/dist/dispatch/lib/engine.js.map +1 -1
- package/dist/dispatch/registry.d.ts.map +1 -1
- package/dist/dispatch/registry.js +81 -0
- package/dist/dispatch/registry.js.map +1 -1
- package/dist/mcp/index.js +13 -4
- package/dist/mcp/index.js.map +2 -2
- package/package.json +3 -3
package/dist/cli/index.js
CHANGED
|
@@ -15411,6 +15411,9 @@ function createPage(input) {
|
|
|
15411
15411
|
};
|
|
15412
15412
|
}
|
|
15413
15413
|
function paginate(items, limit, offset) {
|
|
15414
|
+
if (!items || items.length === 0) {
|
|
15415
|
+
return { items: [], page: { mode: "none" } };
|
|
15416
|
+
}
|
|
15414
15417
|
const total = items.length;
|
|
15415
15418
|
if (limit === void 0 && offset === void 0) {
|
|
15416
15419
|
return { items, page: { mode: "none" } };
|
|
@@ -80504,7 +80507,7 @@ var init_hooks_engine = __esm({
|
|
|
80504
80507
|
// packages/cleo/src/cli/index.ts
|
|
80505
80508
|
import { readFileSync as readFileSync98 } from "node:fs";
|
|
80506
80509
|
import { dirname as dirname24, join as join119 } from "node:path";
|
|
80507
|
-
import { fileURLToPath as
|
|
80510
|
+
import { fileURLToPath as fileURLToPath5 } from "node:url";
|
|
80508
80511
|
|
|
80509
80512
|
// node_modules/.pnpm/citty@0.2.1/node_modules/citty/dist/_chunks/libs/scule.mjs
|
|
80510
80513
|
var NUMBER_CHAR_RE = /\d/;
|
|
@@ -87880,8 +87883,12 @@ var AdminHandler = class {
|
|
|
87880
87883
|
}
|
|
87881
87884
|
case "backup": {
|
|
87882
87885
|
const result = systemListBackups(projectRoot);
|
|
87886
|
+
if (!result.success || !result.data) {
|
|
87887
|
+
return wrapResult(result, "query", "admin", operation, startTime);
|
|
87888
|
+
}
|
|
87889
|
+
const backups = result.data;
|
|
87883
87890
|
return wrapResult(
|
|
87884
|
-
{ success: true, data: { backups
|
|
87891
|
+
{ success: true, data: { backups, count: backups.length } },
|
|
87885
87892
|
"query",
|
|
87886
87893
|
"admin",
|
|
87887
87894
|
operation,
|
|
@@ -90704,16 +90711,18 @@ var PipelineHandler = class {
|
|
|
90704
90711
|
return wrapResult(result, "query", "pipeline", "phase.list", startTime);
|
|
90705
90712
|
}
|
|
90706
90713
|
const listData = result.data;
|
|
90714
|
+
const phases = listData.phases ?? [];
|
|
90715
|
+
const total = listData.summary?.total ?? phases.length;
|
|
90707
90716
|
const { limit, offset } = getListParams(params);
|
|
90708
|
-
const page = paginate(
|
|
90717
|
+
const page = paginate(phases, limit, offset);
|
|
90709
90718
|
return {
|
|
90710
90719
|
_meta: dispatchMeta("query", "pipeline", "phase.list", startTime),
|
|
90711
90720
|
success: true,
|
|
90712
90721
|
data: {
|
|
90713
90722
|
...listData,
|
|
90714
90723
|
phases: page.items,
|
|
90715
|
-
total
|
|
90716
|
-
filtered:
|
|
90724
|
+
total,
|
|
90725
|
+
filtered: total
|
|
90717
90726
|
},
|
|
90718
90727
|
page: page.page
|
|
90719
90728
|
};
|
|
@@ -94581,10 +94590,8 @@ init_src();
|
|
|
94581
94590
|
init_renderers();
|
|
94582
94591
|
import { existsSync as existsSync121, readdirSync as readdirSync39, readFileSync as readFileSync95 } from "node:fs";
|
|
94583
94592
|
import { dirname as dirname22, join as join114 } from "node:path";
|
|
94584
|
-
import { fileURLToPath as fileURLToPath5 } from "node:url";
|
|
94585
94593
|
function findProjectRoot() {
|
|
94586
|
-
|
|
94587
|
-
let currentDir = dirname22(currentFile);
|
|
94594
|
+
let currentDir = process.cwd();
|
|
94588
94595
|
while (currentDir !== "/") {
|
|
94589
94596
|
if (existsSync121(join114(currentDir, "package.json"))) {
|
|
94590
94597
|
return currentDir;
|
|
@@ -94598,6 +94605,38 @@ function findProjectRoot() {
|
|
|
94598
94605
|
function registerDetectDriftCommand(program) {
|
|
94599
94606
|
program.command("detect-drift").description("Detect documentation drift against TypeScript source of truth").action(async () => {
|
|
94600
94607
|
const projectRoot = findProjectRoot();
|
|
94608
|
+
const isCleoRepo = existsSync121(join114(projectRoot, "src", "cli", "commands")) || existsSync121(join114(projectRoot, "packages", "cleo", "src"));
|
|
94609
|
+
if (!isCleoRepo) {
|
|
94610
|
+
const userResult = {
|
|
94611
|
+
summary: { totalChecks: 1, passed: 0, warnings: 0, errors: 0, exitCode: 0 },
|
|
94612
|
+
checks: [],
|
|
94613
|
+
recommendations: []
|
|
94614
|
+
};
|
|
94615
|
+
const injPath = join114(projectRoot, ".cleo", "templates", "CLEO-INJECTION.md");
|
|
94616
|
+
if (existsSync121(injPath)) {
|
|
94617
|
+
const content = safeRead(injPath);
|
|
94618
|
+
userResult.checks.push({
|
|
94619
|
+
name: "Agent injection",
|
|
94620
|
+
status: content.length > 100 ? "pass" : "warn",
|
|
94621
|
+
message: content.length > 100 ? "Agent injection template exists" : "Template appears incomplete",
|
|
94622
|
+
issues: []
|
|
94623
|
+
});
|
|
94624
|
+
userResult.summary.passed = content.length > 100 ? 1 : 0;
|
|
94625
|
+
userResult.summary.warnings = content.length > 100 ? 0 : 1;
|
|
94626
|
+
} else {
|
|
94627
|
+
userResult.checks.push({
|
|
94628
|
+
name: "Agent injection",
|
|
94629
|
+
status: "warn",
|
|
94630
|
+
message: "No injection template found \u2014 run `cleo init` to create one",
|
|
94631
|
+
issues: []
|
|
94632
|
+
});
|
|
94633
|
+
userResult.summary.warnings = 1;
|
|
94634
|
+
}
|
|
94635
|
+
userResult.summary.exitCode = userResult.summary.errors > 0 ? 2 : userResult.summary.warnings > 0 ? 1 : 0;
|
|
94636
|
+
userResult.recommendations.push("detect-drift source checks only apply to the CLEO monorepo. Run from the cleo source tree for full analysis.");
|
|
94637
|
+
cliOutput(userResult, { command: "detect-drift" });
|
|
94638
|
+
process.exit(userResult.summary.exitCode);
|
|
94639
|
+
}
|
|
94601
94640
|
const result = {
|
|
94602
94641
|
summary: {
|
|
94603
94642
|
totalChecks: 0,
|
|
@@ -98986,7 +99025,7 @@ function registerWebCommand(program) {
|
|
|
98986
99025
|
|
|
98987
99026
|
// packages/cleo/src/cli/index.ts
|
|
98988
99027
|
function getPackageVersion() {
|
|
98989
|
-
const pkgPath = join119(dirname24(
|
|
99028
|
+
const pkgPath = join119(dirname24(fileURLToPath5(import.meta.url)), "../../package.json");
|
|
98990
99029
|
const pkg = JSON.parse(readFileSync98(pkgPath, "utf-8"));
|
|
98991
99030
|
return pkg.version;
|
|
98992
99031
|
}
|