skillwiki 0.9.27 → 0.9.29
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/{chunk-4NXBOOYE.js → chunk-T7XG3WFK.js} +3 -2
- package/dist/cli.js +42 -12
- package/dist/skillwiki-mcp.js +1 -1
- package/package.json +1 -1
- package/skills/.claude-plugin/plugin.json +1 -1
- package/skills/.codex-plugin/plugin.json +1 -2
- package/skills/package.json +1 -1
- package/skills/.mcp.json +0 -7
|
@@ -7457,7 +7457,7 @@ import { z as z2 } from "zod";
|
|
|
7457
7457
|
import { join as join26, resolve as resolve7 } from "path";
|
|
7458
7458
|
|
|
7459
7459
|
// src/mcp/allowlist.ts
|
|
7460
|
-
import { resolve as resolve6 } from "path";
|
|
7460
|
+
import { resolve as resolve6, sep as sep5 } from "path";
|
|
7461
7461
|
import { realpathSync } from "fs";
|
|
7462
7462
|
function parseVaultAllowlist(envValue) {
|
|
7463
7463
|
if (envValue === void 0 || envValue.trim() === "") return null;
|
|
@@ -7474,7 +7474,7 @@ function vaultAllowedByList(vaultPath, allowlist) {
|
|
|
7474
7474
|
const resolved = resolve6(canonical);
|
|
7475
7475
|
return allowlist.some((root) => {
|
|
7476
7476
|
const r = resolve6(root);
|
|
7477
|
-
return resolved === r || resolved.startsWith(r +
|
|
7477
|
+
return resolved === r || resolved.startsWith(r + sep5);
|
|
7478
7478
|
});
|
|
7479
7479
|
}
|
|
7480
7480
|
function getVaultAllowlistFromEnv() {
|
|
@@ -8467,6 +8467,7 @@ export {
|
|
|
8467
8467
|
runOrphans,
|
|
8468
8468
|
extractCitationMarkers,
|
|
8469
8469
|
runAudit,
|
|
8470
|
+
findPlugin,
|
|
8470
8471
|
extractTaxonomy,
|
|
8471
8472
|
readLastOp,
|
|
8472
8473
|
appendLastOp,
|
package/dist/cli.js
CHANGED
|
@@ -11,6 +11,7 @@ import {
|
|
|
11
11
|
extractCitationMarkers,
|
|
12
12
|
extractFrontmatter,
|
|
13
13
|
extractTaxonomy,
|
|
14
|
+
findPlugin,
|
|
14
15
|
fixPathTooLong,
|
|
15
16
|
isBlockedHost,
|
|
16
17
|
ok,
|
|
@@ -59,7 +60,7 @@ import {
|
|
|
59
60
|
triggerAutoUpdate,
|
|
60
61
|
writeCache,
|
|
61
62
|
writeDotenv
|
|
62
|
-
} from "./chunk-
|
|
63
|
+
} from "./chunk-T7XG3WFK.js";
|
|
63
64
|
import {
|
|
64
65
|
normalizeDistTag
|
|
65
66
|
} from "./chunk-E6UWZ3S3.js";
|
|
@@ -297,6 +298,28 @@ async function runInstall(input) {
|
|
|
297
298
|
if (entries.length === 0) {
|
|
298
299
|
return { exitCode: ExitCode.PREFLIGHT_FAILED, result: err("PREFLIGHT_FAILED", { reason: "no skills found" }) };
|
|
299
300
|
}
|
|
301
|
+
const defaultTarget = join2(input.home, ".claude", "skills");
|
|
302
|
+
const isDefaultTarget = resolve(input.target) === resolve(defaultTarget);
|
|
303
|
+
const plugin = input.force || !isDefaultTarget ? null : findPlugin(input.home);
|
|
304
|
+
if (plugin) {
|
|
305
|
+
const manifest_path2 = join2(input.target, "wiki-manifest.json");
|
|
306
|
+
const hintLines2 = [
|
|
307
|
+
`deferred to plugin: skillwiki@llm-wiki v${plugin.version}`,
|
|
308
|
+
`plugin provides skills at ${plugin.installPath}`,
|
|
309
|
+
`use --force to install CLI copies into ${input.target} anyway`
|
|
310
|
+
];
|
|
311
|
+
return {
|
|
312
|
+
exitCode: ExitCode.OK,
|
|
313
|
+
result: ok({
|
|
314
|
+
installed: [],
|
|
315
|
+
backed_up: [],
|
|
316
|
+
manifest_path: manifest_path2,
|
|
317
|
+
version_warnings: [],
|
|
318
|
+
deferred_to_plugin: true,
|
|
319
|
+
humanHint: hintLines2.join("\n")
|
|
320
|
+
})
|
|
321
|
+
};
|
|
322
|
+
}
|
|
300
323
|
const installed = [];
|
|
301
324
|
const backed_up = [];
|
|
302
325
|
const version_warnings = [];
|
|
@@ -377,7 +400,7 @@ async function runInstall(input) {
|
|
|
377
400
|
for (const w of version_warnings) hintLines.push(` ${w}`);
|
|
378
401
|
}
|
|
379
402
|
const exitCode = version_warnings.length > 0 ? ExitCode.SKILL_VERSION_MISMATCH : ExitCode.OK;
|
|
380
|
-
return { exitCode, result: ok({ installed, backed_up, manifest_path, version_warnings, humanHint: hintLines.join("\n") }) };
|
|
403
|
+
return { exitCode, result: ok({ installed, backed_up, manifest_path, version_warnings, deferred_to_plugin: false, humanHint: hintLines.join("\n") }) };
|
|
381
404
|
}
|
|
382
405
|
|
|
383
406
|
// src/commands/path.ts
|
|
@@ -1827,19 +1850,23 @@ function resolveGlobalSkillsRoot() {
|
|
|
1827
1850
|
return null;
|
|
1828
1851
|
}
|
|
1829
1852
|
}
|
|
1830
|
-
async function refreshInstalledSkills(target) {
|
|
1853
|
+
async function refreshInstalledSkills(home, target) {
|
|
1831
1854
|
const skillsRoot = resolveGlobalSkillsRoot();
|
|
1832
1855
|
if (!skillsRoot) {
|
|
1833
|
-
return { warnings: ["could not locate global skillwiki installation for skill refresh"], refreshed: false };
|
|
1856
|
+
return { warnings: ["could not locate global skillwiki installation for skill refresh"], refreshed: false, deferred_to_plugin: false };
|
|
1834
1857
|
}
|
|
1835
1858
|
try {
|
|
1836
|
-
const result = await runInstall({ skillsRoot, target, dryRun: false, symlink: false });
|
|
1859
|
+
const result = await runInstall({ skillsRoot, target, dryRun: false, symlink: false, home, force: false });
|
|
1837
1860
|
if (result.result.ok) {
|
|
1838
|
-
return {
|
|
1861
|
+
return {
|
|
1862
|
+
warnings: result.result.data.version_warnings,
|
|
1863
|
+
refreshed: !result.result.data.deferred_to_plugin,
|
|
1864
|
+
deferred_to_plugin: result.result.data.deferred_to_plugin
|
|
1865
|
+
};
|
|
1839
1866
|
}
|
|
1840
|
-
return { warnings: [`skill refresh failed: ${result.result.error}`], refreshed: false };
|
|
1867
|
+
return { warnings: [`skill refresh failed: ${result.result.error}`], refreshed: false, deferred_to_plugin: false };
|
|
1841
1868
|
} catch (e) {
|
|
1842
|
-
return { warnings: [`skill refresh error: ${String(e)}`], refreshed: false };
|
|
1869
|
+
return { warnings: [`skill refresh error: ${String(e)}`], refreshed: false, deferred_to_plugin: false };
|
|
1843
1870
|
}
|
|
1844
1871
|
}
|
|
1845
1872
|
async function runUpdate(input) {
|
|
@@ -1875,6 +1902,7 @@ async function runUpdate(input) {
|
|
|
1875
1902
|
wasAlreadyLatest: true,
|
|
1876
1903
|
version_warnings: [],
|
|
1877
1904
|
skills_refreshed: false,
|
|
1905
|
+
deferred_to_plugin: false,
|
|
1878
1906
|
humanHint: `Already on npm@${tag}: v${currentVersion}`
|
|
1879
1907
|
})
|
|
1880
1908
|
};
|
|
@@ -1891,12 +1919,13 @@ async function runUpdate(input) {
|
|
|
1891
1919
|
};
|
|
1892
1920
|
}
|
|
1893
1921
|
writeCache(input.home, { ...cache, updateAppliedAt: Date.now() });
|
|
1894
|
-
const installResult = await refreshInstalledSkills(target);
|
|
1922
|
+
const installResult = await refreshInstalledSkills(input.home, target);
|
|
1895
1923
|
const version_warnings = installResult.warnings;
|
|
1896
1924
|
const skills_refreshed = installResult.refreshed;
|
|
1925
|
+
const deferred_to_plugin = installResult.deferred_to_plugin;
|
|
1897
1926
|
const hintLines = [
|
|
1898
1927
|
`Updated skillwiki ${currentVersion} \u2192 ${latest} via npm@${tag}`,
|
|
1899
|
-
`skills refreshed: ${skills_refreshed}`
|
|
1928
|
+
deferred_to_plugin ? `skills deferred to plugin channel (skillwiki@llm-wiki)` : `skills refreshed: ${skills_refreshed}`
|
|
1900
1929
|
];
|
|
1901
1930
|
if (version_warnings.length > 0) {
|
|
1902
1931
|
hintLines.push(`version warnings: ${version_warnings.length}`);
|
|
@@ -1910,6 +1939,7 @@ async function runUpdate(input) {
|
|
|
1910
1939
|
wasAlreadyLatest: false,
|
|
1911
1940
|
version_warnings,
|
|
1912
1941
|
skills_refreshed,
|
|
1942
|
+
deferred_to_plugin,
|
|
1913
1943
|
humanHint: hintLines.join("\n")
|
|
1914
1944
|
})
|
|
1915
1945
|
};
|
|
@@ -4407,9 +4437,9 @@ program.command("orphans [vault]").description("find pages not referenced by any
|
|
|
4407
4437
|
wiki: opts.wiki
|
|
4408
4438
|
})));
|
|
4409
4439
|
program.command("audit <file>").description("audit citation markers and source provenance for a vault page").action(async (file) => emit(await runAudit({ file })));
|
|
4410
|
-
program.command("install").description("install skillwiki SKILL.md files into ~/.claude/skills/").option("--target <dir>", "target install directory", `${process.env.HOME ?? ""}/.claude/skills/`).option("--dry-run", "preview only", false).option("--skills-root <dir>", "source skills directory (defaults to packaged)").option("--symlink", "create symlinks instead of copies (dev mode \u2014 edits to source are immediately visible)", false).action(async (opts) => {
|
|
4440
|
+
program.command("install").description("install skillwiki SKILL.md files into ~/.claude/skills/").option("--target <dir>", "target install directory", `${process.env.HOME ?? ""}/.claude/skills/`).option("--dry-run", "preview only", false).option("--skills-root <dir>", "source skills directory (defaults to packaged)").option("--symlink", "create symlinks instead of copies (dev mode \u2014 edits to source are immediately visible)", false).option("--force", "install CLI copies even when the skillwiki@llm-wiki plugin channel is active", false).action(async (opts) => {
|
|
4411
4441
|
const skillsRoot = opts.skillsRoot ?? new URL("../skills/", import.meta.url).pathname;
|
|
4412
|
-
emit(await runInstall({ skillsRoot, target: opts.target, dryRun: !!opts.dryRun, symlink: !!opts.symlink }));
|
|
4442
|
+
emit(await runInstall({ skillsRoot, target: opts.target, dryRun: !!opts.dryRun, symlink: !!opts.symlink, home: process.env.HOME ?? "", force: !!opts.force }));
|
|
4413
4443
|
});
|
|
4414
4444
|
program.command("path").description("show the resolved vault path").option("--vault <dir>", "explicit vault override (runtime)").option("--target <dir>", "explicit target override (init-time)").option("--wiki <name>", "wiki profile name").option("--init-time", "use init-time chain instead of runtime", false).option("--explain", "include resolution chain in output", false).action(async (opts) => {
|
|
4415
4445
|
const initTime = !!opts.initTime;
|
package/dist/skillwiki-mcp.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "skillwiki",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.29",
|
|
4
4
|
"skills": "./",
|
|
5
5
|
"description": "Project-aware Karpathy-style knowledge base for Claude Code: 18 prompt-only skills (wiki-*, proj-*, using-skillwiki) backed by the deterministic `skillwiki` CLI.",
|
|
6
6
|
"author": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "skillwiki",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.29",
|
|
4
4
|
"description": "Project-aware Karpathy-style knowledge base for Codex with 18 prompt-only skills backed by the deterministic skillwiki CLI.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "karlorz",
|
|
@@ -18,7 +18,6 @@
|
|
|
18
18
|
"karpathy"
|
|
19
19
|
],
|
|
20
20
|
"skills": "./skills/",
|
|
21
|
-
"mcpServers": "./.mcp.json",
|
|
22
21
|
"hooks": "./hooks/hooks-codex.json",
|
|
23
22
|
"interface": {
|
|
24
23
|
"displayName": "SkillWiki",
|
package/skills/package.json
CHANGED