@cleocode/cleo 2026.4.112 → 2026.4.114
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/index.js +75 -24
- package/dist/cli/index.js.map +4 -4
- package/package.json +9 -9
package/dist/cli/index.js
CHANGED
|
@@ -31868,6 +31868,17 @@ function resolveFormat(opts, defaults) {
|
|
|
31868
31868
|
|
|
31869
31869
|
// packages/cleo/src/cli/commands/adapter.ts
|
|
31870
31870
|
init_cli();
|
|
31871
|
+
|
|
31872
|
+
// packages/cleo/src/cli/lib/subcommand-guard.ts
|
|
31873
|
+
function isSubCommandDispatch(rawArgs, subCommands2) {
|
|
31874
|
+
if (!rawArgs || !subCommands2) return false;
|
|
31875
|
+
const firstArg = rawArgs.find((a) => !a.startsWith("-"));
|
|
31876
|
+
if (!firstArg) return false;
|
|
31877
|
+
if (typeof subCommands2 !== "object") return false;
|
|
31878
|
+
return firstArg in subCommands2;
|
|
31879
|
+
}
|
|
31880
|
+
|
|
31881
|
+
// packages/cleo/src/cli/commands/adapter.ts
|
|
31871
31882
|
var listCommand = defineCommand({
|
|
31872
31883
|
meta: { name: "list", description: "List all discovered provider adapters" },
|
|
31873
31884
|
async run() {
|
|
@@ -31979,7 +31990,8 @@ var adapterCommand = defineCommand({
|
|
|
31979
31990
|
activate: activateCommand,
|
|
31980
31991
|
dispose: disposeCommand
|
|
31981
31992
|
},
|
|
31982
|
-
async run() {
|
|
31993
|
+
async run({ cmd, rawArgs }) {
|
|
31994
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
31983
31995
|
await dispatchFromCli(
|
|
31984
31996
|
"query",
|
|
31985
31997
|
"tools",
|
|
@@ -36381,7 +36393,8 @@ var backupCommand = defineCommand({
|
|
|
36381
36393
|
import: importCommand,
|
|
36382
36394
|
inspect: backupInspectSubCommand
|
|
36383
36395
|
},
|
|
36384
|
-
async run() {
|
|
36396
|
+
async run({ cmd, rawArgs }) {
|
|
36397
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
36385
36398
|
await dispatchFromCli("mutate", "admin", "backup", {}, { command: "backup" });
|
|
36386
36399
|
}
|
|
36387
36400
|
});
|
|
@@ -39056,7 +39069,8 @@ var daemonCommand = defineCommand({
|
|
|
39056
39069
|
stop: stopCommand3,
|
|
39057
39070
|
status: statusCommand4
|
|
39058
39071
|
},
|
|
39059
|
-
async run({ args }) {
|
|
39072
|
+
async run({ args, cmd, rawArgs }) {
|
|
39073
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
39060
39074
|
const cleoDir = args["cleo-dir"] ?? join11(homedir2(), ".cleo");
|
|
39061
39075
|
await showDaemonStatus(cleoDir, args.json ?? false);
|
|
39062
39076
|
}
|
|
@@ -42721,6 +42735,7 @@ var logCommand2 = defineCommand({
|
|
|
42721
42735
|
});
|
|
42722
42736
|
|
|
42723
42737
|
// packages/cleo/src/cli/commands/manifest.ts
|
|
42738
|
+
import { buildManifestEntryFromShorthand } from "@cleocode/core/memory/manifest-builder.js";
|
|
42724
42739
|
init_cli();
|
|
42725
42740
|
var showCommand7 = defineCommand({
|
|
42726
42741
|
meta: {
|
|
@@ -42863,24 +42878,32 @@ var statsCommand3 = defineCommand({
|
|
|
42863
42878
|
var appendCommand = defineCommand({
|
|
42864
42879
|
meta: {
|
|
42865
42880
|
name: "append",
|
|
42866
|
-
description: "Append a new manifest entry"
|
|
42881
|
+
description: "Append a new manifest entry (pipeline_manifest table). Accepts either a full --entry JSON blob / --file / stdin, OR the shorthand --task + --type + --content flags which build a valid entry with sensible defaults for id/file/title/date/etc."
|
|
42867
42882
|
},
|
|
42868
42883
|
args: {
|
|
42869
42884
|
entry: {
|
|
42870
42885
|
type: "string",
|
|
42871
|
-
description: "JSON string of entry fields"
|
|
42886
|
+
description: "JSON string of entry fields (full ManifestEntry shape)"
|
|
42872
42887
|
},
|
|
42873
42888
|
task: {
|
|
42874
42889
|
type: "string",
|
|
42875
|
-
description: "Task ID to associate (shorthand
|
|
42890
|
+
description: "Task ID to associate \u2014 becomes linked_tasks[0] + id prefix (shorthand)"
|
|
42876
42891
|
},
|
|
42877
42892
|
type: {
|
|
42878
42893
|
type: "string",
|
|
42879
|
-
description: "Entry type (
|
|
42894
|
+
description: "Entry type \u2014 becomes agent_type (e.g. research, implementation, decomposition) (shorthand)"
|
|
42880
42895
|
},
|
|
42881
42896
|
content: {
|
|
42882
42897
|
type: "string",
|
|
42883
|
-
description: "
|
|
42898
|
+
description: "One-paragraph summary \u2014 becomes key_findings[0] and title (first line) (shorthand)"
|
|
42899
|
+
},
|
|
42900
|
+
title: {
|
|
42901
|
+
type: "string",
|
|
42902
|
+
description: "Explicit title override for shorthand mode"
|
|
42903
|
+
},
|
|
42904
|
+
status: {
|
|
42905
|
+
type: "string",
|
|
42906
|
+
description: "Entry status: completed (default) | partial | blocked (shorthand)"
|
|
42884
42907
|
},
|
|
42885
42908
|
file: {
|
|
42886
42909
|
type: "string",
|
|
@@ -42889,6 +42912,7 @@ var appendCommand = defineCommand({
|
|
|
42889
42912
|
},
|
|
42890
42913
|
async run({ args }) {
|
|
42891
42914
|
let entry;
|
|
42915
|
+
const hasShorthand = Boolean(args.task || args.type || args.content);
|
|
42892
42916
|
if (args.entry) {
|
|
42893
42917
|
try {
|
|
42894
42918
|
entry = JSON.parse(args.entry);
|
|
@@ -42905,10 +42929,22 @@ var appendCommand = defineCommand({
|
|
|
42905
42929
|
console.error(`Error: failed to read or parse ${args.file}`);
|
|
42906
42930
|
process.exit(1);
|
|
42907
42931
|
}
|
|
42932
|
+
} else if (hasShorthand) {
|
|
42933
|
+
entry = {
|
|
42934
|
+
...buildManifestEntryFromShorthand({
|
|
42935
|
+
task: args.task,
|
|
42936
|
+
type: args.type,
|
|
42937
|
+
content: args.content,
|
|
42938
|
+
title: args.title,
|
|
42939
|
+
status: args.status
|
|
42940
|
+
})
|
|
42941
|
+
};
|
|
42908
42942
|
} else {
|
|
42909
42943
|
const stdinData = await readStdin();
|
|
42910
42944
|
if (!stdinData) {
|
|
42911
|
-
console.error(
|
|
42945
|
+
console.error(
|
|
42946
|
+
"Error: must provide --entry JSON, --file path, stdin, or shorthand (--task + --type + --content)"
|
|
42947
|
+
);
|
|
42912
42948
|
process.exit(1);
|
|
42913
42949
|
}
|
|
42914
42950
|
try {
|
|
@@ -42918,14 +42954,22 @@ var appendCommand = defineCommand({
|
|
|
42918
42954
|
process.exit(1);
|
|
42919
42955
|
}
|
|
42920
42956
|
}
|
|
42921
|
-
if (args.
|
|
42922
|
-
|
|
42923
|
-
|
|
42924
|
-
|
|
42925
|
-
|
|
42926
|
-
|
|
42927
|
-
|
|
42928
|
-
|
|
42957
|
+
if ((args.entry || args.file) && hasShorthand) {
|
|
42958
|
+
if (args.task) {
|
|
42959
|
+
entry.linked_tasks = Array.isArray(entry.linked_tasks) ? [args.task, ...entry.linked_tasks.filter((t) => t !== args.task)] : [args.task];
|
|
42960
|
+
}
|
|
42961
|
+
if (args.type) {
|
|
42962
|
+
entry.agent_type = args.type;
|
|
42963
|
+
}
|
|
42964
|
+
if (args.content && !entry.key_findings) {
|
|
42965
|
+
entry.key_findings = [args.content];
|
|
42966
|
+
}
|
|
42967
|
+
if (args.title) {
|
|
42968
|
+
entry.title = args.title;
|
|
42969
|
+
}
|
|
42970
|
+
if (args.status) {
|
|
42971
|
+
entry.status = args.status;
|
|
42972
|
+
}
|
|
42929
42973
|
}
|
|
42930
42974
|
await dispatchFromCli(
|
|
42931
42975
|
"mutate",
|
|
@@ -42995,7 +43039,8 @@ var manifestCommand = defineCommand({
|
|
|
42995
43039
|
append: appendCommand,
|
|
42996
43040
|
archive: archiveCommand2
|
|
42997
43041
|
},
|
|
42998
|
-
async run({ cmd }) {
|
|
43042
|
+
async run({ cmd, rawArgs }) {
|
|
43043
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
42999
43044
|
await showUsage(cmd);
|
|
43000
43045
|
}
|
|
43001
43046
|
});
|
|
@@ -51595,7 +51640,8 @@ var providerCommand = defineCommand({
|
|
|
51595
51640
|
hooks: hooksCommand,
|
|
51596
51641
|
inject: injectCommand2
|
|
51597
51642
|
},
|
|
51598
|
-
async run() {
|
|
51643
|
+
async run({ cmd, rawArgs }) {
|
|
51644
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
51599
51645
|
await dispatchFromCli(
|
|
51600
51646
|
"query",
|
|
51601
51647
|
"tools",
|
|
@@ -54482,7 +54528,8 @@ var baselineSub = defineCommand({
|
|
|
54482
54528
|
subCommands: {
|
|
54483
54529
|
capture: baselineCaptureSub
|
|
54484
54530
|
},
|
|
54485
|
-
async run({ args }) {
|
|
54531
|
+
async run({ args, cmd, rawArgs }) {
|
|
54532
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
54486
54533
|
const jsonMode = args.json === true;
|
|
54487
54534
|
emitSuccess(
|
|
54488
54535
|
{ message: "Use: cleo sentient baseline capture <sha>" },
|
|
@@ -54595,7 +54642,8 @@ var allowlistSub = defineCommand({
|
|
|
54595
54642
|
add: allowlistAddSub,
|
|
54596
54643
|
remove: allowlistRemoveSub
|
|
54597
54644
|
},
|
|
54598
|
-
async run({ args }) {
|
|
54645
|
+
async run({ args, cmd, rawArgs }) {
|
|
54646
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
54599
54647
|
const jsonMode = args.json === true;
|
|
54600
54648
|
emitSuccess(
|
|
54601
54649
|
{ message: "Use: cleo sentient allowlist list|add|remove" },
|
|
@@ -54620,7 +54668,8 @@ var sentientCommand = defineCommand({
|
|
|
54620
54668
|
baseline: baselineSub,
|
|
54621
54669
|
allowlist: allowlistSub
|
|
54622
54670
|
},
|
|
54623
|
-
async run({ args }) {
|
|
54671
|
+
async run({ args, cmd, rawArgs }) {
|
|
54672
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
54624
54673
|
const projectRoot = resolveProjectRoot7(args.project);
|
|
54625
54674
|
const jsonMode = args.json === true;
|
|
54626
54675
|
try {
|
|
@@ -55587,7 +55636,8 @@ var skillsCommand2 = defineCommand({
|
|
|
55587
55636
|
deps: depsCommand3,
|
|
55588
55637
|
"spawn-providers": spawnProvidersCommand
|
|
55589
55638
|
},
|
|
55590
|
-
async run() {
|
|
55639
|
+
async run({ cmd, rawArgs }) {
|
|
55640
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
55591
55641
|
await dispatchFromCli(
|
|
55592
55642
|
"query",
|
|
55593
55643
|
"tools",
|
|
@@ -55759,7 +55809,8 @@ var statsCommand6 = defineCommand({
|
|
|
55759
55809
|
subCommands: {
|
|
55760
55810
|
compliance: complianceCommand2
|
|
55761
55811
|
},
|
|
55762
|
-
async run({ args }) {
|
|
55812
|
+
async run({ args, cmd, rawArgs }) {
|
|
55813
|
+
if (isSubCommandDispatch(rawArgs, cmd.subCommands)) return;
|
|
55763
55814
|
await dispatchFromCli(
|
|
55764
55815
|
"query",
|
|
55765
55816
|
"admin",
|