@pikku/skills 0.12.35 → 0.12.38
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/README.md +9 -4
- package/dist/index.d.ts +7 -4
- package/dist/index.js +9 -5
- package/dist/skills.gen.d.ts +1 -0
- package/dist/skills.gen.js +5 -3
- package/dist/snippets.d.ts +26 -0
- package/dist/snippets.js +148 -0
- package/package.json +2 -2
- package/skills/pikku-addon/SKILL.md +70 -24
- package/skills/pikku-addon/references/addon-package-manifest.md +9 -4
- package/skills/pikku-addon/references/openapi.md +130 -0
- package/skills/pikku-agent/references/agents.md +3 -1
- package/skills/pikku-auth/references/better-auth.md +33 -2
- package/skills/pikku-build/SKILL.md +94 -6
- package/skills/pikku-build/references/app.md +82 -12
- package/skills/pikku-build/references/design.md +16 -5
- package/skills/pikku-build/references/feature.md +23 -96
- package/skills/pikku-build/references/openapi.md +119 -0
- package/skills/pikku-build/references/platform.md +4 -0
- package/skills/pikku-build/references/quick.md +16 -6
- package/skills/pikku-changes/SKILL.md +172 -0
- package/skills/pikku-concepts/SKILL.md +33 -138
- package/skills/pikku-concepts/references/bootstrap.md +58 -0
- package/skills/pikku-concepts/references/concept-mapping.md +16 -0
- package/skills/pikku-concepts/references/language.md +87 -0
- package/skills/pikku-deploy/SKILL.md +1 -1
- package/skills/pikku-fabric/SKILL.md +13 -13
- package/skills/pikku-guide/SKILL.md +264 -0
- package/skills/pikku-kysely/SKILL.md +1 -1
- package/skills/pikku-n8n-import/SKILL.md +4 -3
- package/skills/pikku-react/references/client.md +12 -0
- package/skills/pikku-realtime/SKILL.md +6 -6
- package/skills/pikku-report/SKILL.md +143 -0
- package/skills/pikku-scenario/SKILL.md +71 -562
- package/skills/pikku-scenario/references/browser.md +59 -0
- package/skills/pikku-scenario/references/coverage.md +70 -0
- package/skills/pikku-scenario/references/personas.md +149 -0
- package/skills/pikku-scenario/references/steps.md +366 -0
- package/skills/pikku-service-backends/SKILL.md +1 -1
- package/skills/pikku-wiring/SKILL.md +1 -1
- package/skills/pikku-workflow/SKILL.md +7 -8
package/README.md
CHANGED
|
@@ -32,7 +32,12 @@ for (const name of await listSkillNames()) {
|
|
|
32
32
|
```
|
|
33
33
|
|
|
34
34
|
Reads prefer the `skills/` directory on disk, so editing a `SKILL.md` is live
|
|
35
|
-
immediately.
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
35
|
+
immediately. A fence marked ```` ```ts snippet:<region> ```` is expanded at read
|
|
36
|
+
time from the embedded snippet map, so an installed copy shows the compiled code
|
|
37
|
+
even though the source keeps the placeholder. `SKILL_FILES` is the same content
|
|
38
|
+
as an embedded path → contents map (already expanded), which is what makes the
|
|
39
|
+
skills available inside the `bun --compile` CLI binaries where no filesystem copy
|
|
40
|
+
exists. Regenerate it with `bun run embed` after changing anything under
|
|
41
|
+
`skills/` — that is also when snippets are collected from
|
|
42
|
+
`examples/online-shop`, and a fence naming a region that does not exist fails
|
|
43
|
+
the embed.
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { SKILL_FILES } from './skills.gen.js';
|
|
2
|
-
export { SKILL_FILES };
|
|
1
|
+
import { SKILL_FILES, SKILL_SNIPPETS } from './skills.gen.js';
|
|
2
|
+
export { SKILL_FILES, SKILL_SNIPPETS };
|
|
3
|
+
export { collectSnippets, expandSkillMarkdown, snippetRegionsIn, DuplicateSnippetError, MissingSnippetError, UnclosedSnippetError, } from './snippets.js';
|
|
3
4
|
/**
|
|
4
5
|
* Absolute path to the `skills/` directory shipped beside this module, or `null`
|
|
5
6
|
* when there is no filesystem copy to read.
|
|
@@ -12,8 +13,10 @@ export { SKILL_FILES };
|
|
|
12
13
|
export declare const skillsDir: string | null;
|
|
13
14
|
/**
|
|
14
15
|
* Reading prefers the filesystem so that editing a SKILL.md is immediately live
|
|
15
|
-
* for `pikku skills install` without re-running `
|
|
16
|
-
* fallback for bundled contexts.
|
|
16
|
+
* for `pikku skills install` without re-running `bun run embed`; the manifest is
|
|
17
|
+
* the fallback for bundled contexts. A filesystem read expands `snippet:` fences
|
|
18
|
+
* from the embedded snippet map, so the installed text matches the manifest
|
|
19
|
+
* even though the source keeps placeholders.
|
|
17
20
|
*/
|
|
18
21
|
export declare const listSkillNames: () => Promise<string[]>;
|
|
19
22
|
/** Every file belonging to one skill, as paths relative to the skills root. */
|
package/dist/index.js
CHANGED
|
@@ -2,8 +2,10 @@ import { existsSync } from 'fs';
|
|
|
2
2
|
import { readdir, readFile } from 'fs/promises';
|
|
3
3
|
import { dirname, join, relative, sep } from 'path';
|
|
4
4
|
import { fileURLToPath } from 'url';
|
|
5
|
-
import { SKILL_FILES } from './skills.gen.js';
|
|
6
|
-
|
|
5
|
+
import { SKILL_FILES, SKILL_SNIPPETS } from './skills.gen.js';
|
|
6
|
+
import { expandSkillMarkdown } from './snippets.js';
|
|
7
|
+
export { SKILL_FILES, SKILL_SNIPPETS };
|
|
8
|
+
export { collectSnippets, expandSkillMarkdown, snippetRegionsIn, DuplicateSnippetError, MissingSnippetError, UnclosedSnippetError, } from './snippets.js';
|
|
7
9
|
/**
|
|
8
10
|
* Absolute path to the `skills/` directory shipped beside this module, or `null`
|
|
9
11
|
* when there is no filesystem copy to read.
|
|
@@ -20,8 +22,10 @@ export const skillsDir = (() => {
|
|
|
20
22
|
const toPosix = (path) => path.split(sep).join('/');
|
|
21
23
|
/**
|
|
22
24
|
* Reading prefers the filesystem so that editing a SKILL.md is immediately live
|
|
23
|
-
* for `pikku skills install` without re-running `
|
|
24
|
-
* fallback for bundled contexts.
|
|
25
|
+
* for `pikku skills install` without re-running `bun run embed`; the manifest is
|
|
26
|
+
* the fallback for bundled contexts. A filesystem read expands `snippet:` fences
|
|
27
|
+
* from the embedded snippet map, so the installed text matches the manifest
|
|
28
|
+
* even though the source keeps placeholders.
|
|
25
29
|
*/
|
|
26
30
|
export const listSkillNames = async () => {
|
|
27
31
|
if (skillsDir) {
|
|
@@ -68,7 +72,7 @@ export const readSkillFile = async (path) => {
|
|
|
68
72
|
const full = join(skillsDir, ...path.split('/'));
|
|
69
73
|
if (!existsSync(full))
|
|
70
74
|
return null;
|
|
71
|
-
return readFile(full, 'utf-8');
|
|
75
|
+
return expandSkillMarkdown(await readFile(full, 'utf-8'), SKILL_SNIPPETS, path);
|
|
72
76
|
}
|
|
73
77
|
return SKILL_FILES[path] ?? null;
|
|
74
78
|
};
|
package/dist/skills.gen.d.ts
CHANGED