harnessed 4.16.1 → 4.16.3
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.mjs +31 -7
- package/dist/cli.mjs.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/manifests/skill-packs/gstack.yaml +7 -4
- package/manifests/skill-packs/mattpocock-skills.yaml +1 -1
- package/package.json +1 -1
- package/routing/decision_rules.yaml +2 -5
- package/workflows/capabilities.yaml +25 -24
- package/workflows/role-prompts.yaml +7 -10
- package/workflows/role-prompts.zh-Hans.yaml +6 -10
- package/workflows/task/auto/SKILL.md +1 -2
- package/workflows/task/auto/SKILL.zh-Hans.md +1 -2
- package/workflows/task/auto/workflow.yaml +1 -2
- package/workflows/task/code/SKILL.md +4 -5
- package/workflows/task/code/SKILL.zh-Hans.md +4 -5
- package/workflows/task/code/workflow.yaml +6 -9
package/dist/cli.mjs
CHANGED
|
@@ -38,7 +38,7 @@ var init_package = __esm({
|
|
|
38
38
|
"package.json"() {
|
|
39
39
|
package_default = {
|
|
40
40
|
name: "harnessed",
|
|
41
|
-
version: "4.16.
|
|
41
|
+
version: "4.16.3",
|
|
42
42
|
description: "AI coding harness package manager + composition orchestrator",
|
|
43
43
|
type: "module",
|
|
44
44
|
license: "Apache-2.0",
|
|
@@ -6330,7 +6330,7 @@ function gitRevParseHead(cwd, timeoutMs = 1e4) {
|
|
|
6330
6330
|
});
|
|
6331
6331
|
});
|
|
6332
6332
|
}
|
|
6333
|
-
function
|
|
6333
|
+
function extractRawCloneDest(cmd) {
|
|
6334
6334
|
const idx = cmd.indexOf("git clone");
|
|
6335
6335
|
if (idx < 0) return null;
|
|
6336
6336
|
const tail = cmd.slice(idx + "git clone".length).trim();
|
|
@@ -6349,6 +6349,12 @@ function extractCloneTarget(cmd) {
|
|
|
6349
6349
|
}
|
|
6350
6350
|
const dest = tokens[i + 1];
|
|
6351
6351
|
if (!dest || dest === "&&" || dest === ";" || dest === "|") return null;
|
|
6352
|
+
return { raw: dest, cloneIdx: idx };
|
|
6353
|
+
}
|
|
6354
|
+
function extractCloneTarget(cmd) {
|
|
6355
|
+
const parsed = extractRawCloneDest(cmd);
|
|
6356
|
+
if (!parsed) return null;
|
|
6357
|
+
const dest = parsed.raw;
|
|
6352
6358
|
if (dest.startsWith("~/")) {
|
|
6353
6359
|
const home = process.env.HOME ?? process.env.USERPROFILE;
|
|
6354
6360
|
if (!home) return null;
|
|
@@ -6356,6 +6362,18 @@ function extractCloneTarget(cmd) {
|
|
|
6356
6362
|
}
|
|
6357
6363
|
return dest;
|
|
6358
6364
|
}
|
|
6365
|
+
function isSelfCleaningCloneCmd(cmd) {
|
|
6366
|
+
const parsed = extractRawCloneDest(cmd);
|
|
6367
|
+
if (!parsed) return false;
|
|
6368
|
+
const needle = `rm -rf ${parsed.raw}`;
|
|
6369
|
+
let idx = cmd.indexOf(needle, parsed.cloneIdx);
|
|
6370
|
+
while (idx >= 0) {
|
|
6371
|
+
const after = cmd[idx + needle.length];
|
|
6372
|
+
if (after === void 0 || /\s/.test(after)) return true;
|
|
6373
|
+
idx = cmd.indexOf(needle, idx + 1);
|
|
6374
|
+
}
|
|
6375
|
+
return false;
|
|
6376
|
+
}
|
|
6359
6377
|
var installGitCloneWithSetup;
|
|
6360
6378
|
var init_gitCloneWithSetup2 = __esm({
|
|
6361
6379
|
"src/installers/gitCloneWithSetup.ts"() {
|
|
@@ -6461,8 +6479,8 @@ var init_gitCloneWithSetup2 = __esm({
|
|
|
6461
6479
|
)
|
|
6462
6480
|
};
|
|
6463
6481
|
}
|
|
6464
|
-
const rp = await gitRevParseHead(cloneTarget);
|
|
6465
|
-
if (rp.exit !== 0 || !rp.sha) {
|
|
6482
|
+
const rp = isSelfCleaningCloneCmd(install.cmd) ? null : await gitRevParseHead(cloneTarget);
|
|
6483
|
+
if (rp === null) ; else if (rp.exit !== 0 || !rp.sha) {
|
|
6466
6484
|
console.warn(
|
|
6467
6485
|
` \u26A0 ${name}: git_ref SHA pin '${install.git_ref}' unverifiable \u2014 \`git rev-parse HEAD\` exit ${rp.exit} in ${cloneTarget} (the install cmd may remove its own clone dir); falling back to the manifest verify cmd as the install authority`
|
|
6468
6486
|
);
|
|
@@ -6560,6 +6578,7 @@ var init_mcpHttpAdd2 = __esm({
|
|
|
6560
6578
|
init_runClaudeArgs();
|
|
6561
6579
|
init_safeCwd();
|
|
6562
6580
|
init_state2();
|
|
6581
|
+
init_verifyMessage();
|
|
6563
6582
|
installMcpHttpAdd = async (ctx) => {
|
|
6564
6583
|
const install = ctx.manifest.spec.install;
|
|
6565
6584
|
if (install.method !== "mcp-http-add") {
|
|
@@ -6695,7 +6714,9 @@ ${newEntry}
|
|
|
6695
6714
|
error: err(
|
|
6696
6715
|
ctx,
|
|
6697
6716
|
"/spec/install/cmd",
|
|
6698
|
-
|
|
6717
|
+
// v4.16.3 — formatSpawnFail parity with the other 4 installers
|
|
6718
|
+
// (tail-END + stdout fallback; CC CLI errors can land on stdout).
|
|
6719
|
+
formatSpawnFail(`${bin} mcp add (http)`, r.exitCode, r.stdout, r.stderr),
|
|
6699
6720
|
"install-failed"
|
|
6700
6721
|
)
|
|
6701
6722
|
};
|
|
@@ -6737,6 +6758,7 @@ var init_mcpStdioAdd2 = __esm({
|
|
|
6737
6758
|
init_runClaudeArgs();
|
|
6738
6759
|
init_safeCwd();
|
|
6739
6760
|
init_state2();
|
|
6761
|
+
init_verifyMessage();
|
|
6740
6762
|
installMcpStdioAdd = async (ctx) => {
|
|
6741
6763
|
const install = ctx.manifest.spec.install;
|
|
6742
6764
|
if (install.method !== "mcp-stdio-add") {
|
|
@@ -6838,7 +6860,9 @@ ${newEntry}
|
|
|
6838
6860
|
error: err(
|
|
6839
6861
|
ctx,
|
|
6840
6862
|
"/spec/install/cmd",
|
|
6841
|
-
|
|
6863
|
+
// v4.16.3 — formatSpawnFail parity with the other 4 installers
|
|
6864
|
+
// (tail-END + stdout fallback; CC CLI errors can land on stdout).
|
|
6865
|
+
formatSpawnFail(`${bin} mcp add`, r.exitCode, r.stdout, r.stderr),
|
|
6842
6866
|
"install-failed"
|
|
6843
6867
|
)
|
|
6844
6868
|
};
|
|
@@ -9790,7 +9814,7 @@ async function runStepBInstall(manifestPaths, runOpts = {}) {
|
|
|
9790
9814
|
try {
|
|
9791
9815
|
const r = await runInstall(manifest, opts);
|
|
9792
9816
|
if ("aborted" in r) {
|
|
9793
|
-
const reason = r.reason === "harness-mismatch" ? `harness-mismatch \u2014 claude-only install method (no ${detectPlatform().id} equivalent)` : r.reason;
|
|
9817
|
+
const reason = r.reason === "harness-mismatch" ? `harness-mismatch \u2014 claude-only install method (no ${detectPlatform().id} equivalent)` : r.reason === "level-flag-missing" && runOpts.updateInstalled === true ? `L4 system-scope \u2014 excluded from force-update; update manually: \`${manifest.spec.install.cmd}\`` : r.reason;
|
|
9794
9818
|
return emit({ status: "skipped", name, reason });
|
|
9795
9819
|
}
|
|
9796
9820
|
if (r.ok && "alreadyInstalled" in r && r.alreadyInstalled)
|