skillspub 0.1.0
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/LICENSE +21 -0
- package/README.md +86 -0
- package/dist/catalog.js +352 -0
- package/dist/cli.js +1562 -0
- package/dist/core.js +31 -0
- package/dist/explain.js +307 -0
- package/dist/harnesses/claude.js +95 -0
- package/dist/harnesses/grok.js +746 -0
- package/dist/harnesses/pi.js +1380 -0
- package/dist/harnesses/registry.js +30 -0
- package/dist/harnesses/target.js +5 -0
- package/dist/harnesses/types.js +1 -0
- package/dist/inventory.js +1437 -0
- package/dist/npx-skills.js +273 -0
- package/dist/reconcile.js +1014 -0
- package/dist/shared.js +1411 -0
- package/dist/source-verification.js +297 -0
- package/dist/targets/shared.js +13 -0
- package/dist/tui.js +2373 -0
- package/dist/view.js +321 -0
- package/package.json +51 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { claudeAdapter } from "./claude.js";
|
|
2
|
+
import { grokAdapter } from "./grok.js";
|
|
3
|
+
import { piAdapter } from "./pi.js";
|
|
4
|
+
const adapters = [claudeAdapter, grokAdapter, piAdapter];
|
|
5
|
+
export function harnessAdapters() {
|
|
6
|
+
return adapters;
|
|
7
|
+
}
|
|
8
|
+
function harnessAdapter(key) {
|
|
9
|
+
const adapter = adapters.find((candidate) => candidate.key === key);
|
|
10
|
+
if (!adapter)
|
|
11
|
+
throw new Error(`unknown Harness: ${key}`);
|
|
12
|
+
return adapter;
|
|
13
|
+
}
|
|
14
|
+
export function inspectHarness(key, home, targets, projectPath) {
|
|
15
|
+
return harnessAdapter(key).inspect(home, targets, projectPath);
|
|
16
|
+
}
|
|
17
|
+
export function planHarnessOperation(key, operation, home, targets, projectPath) {
|
|
18
|
+
const adapter = harnessAdapter(key);
|
|
19
|
+
const plan = adapter.operations?.[operation];
|
|
20
|
+
if (!plan)
|
|
21
|
+
throw new Error(`${adapter.name} does not support ${operation}; no configuration write is required.`);
|
|
22
|
+
return plan(home, targets, projectPath);
|
|
23
|
+
}
|
|
24
|
+
export function inspectHarnesses(home, targets, projectPath) {
|
|
25
|
+
const inspections = adapters.map((adapter) => adapter.inspect(home, targets, projectPath));
|
|
26
|
+
return {
|
|
27
|
+
detected: inspections.filter(({ detected }) => detected),
|
|
28
|
+
available: inspections.filter(({ detected }) => !detected),
|
|
29
|
+
};
|
|
30
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|