pi-skillful 0.3.9 → 0.3.12

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/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.3.12 - 2026-07-12
4
+
5
+ ## 0.3.11 - 2026-07-01
6
+
3
7
  ## 0.3.9 - 2026-06-14
4
8
 
5
9
  All notable changes to this project will be documented in this file.
@@ -10,6 +14,19 @@ This project follows the spirit of [Keep a Changelog](https://keepachangelog.com
10
14
 
11
15
  ### Fixed
12
16
 
17
+ - Preserve configured hidden skills at session start. Skillful no longer treats a temporarily incomplete loaded-skill list as authoritative and removes global or project visibility settings.
18
+
19
+ ## [0.3.10] - 2026-07-01
20
+
21
+ ### Fixed
22
+
23
+ - Color hidden skills in the startup `[Skills]` list on `@earendil-works/pi-coding-agent` 0.80+. The 0.80 release moved the loaded-resources container out of `chatContainer`, so the existing prototype patch walked the wrong container and the red/dim colorization no longer applied. The patch now also walks `loadedResourcesContainer`, where 0.80 actually renders the `[Skills]` section.
24
+ - Bumped dev dependency range to `^0.80.0` to match the new floor.
25
+
26
+ ## [0.3.9] - 2026-06-14
27
+
28
+ ### Fixed
29
+
13
30
  - Skipped Pi package-bundled skills when applying hidden-skill and toggle-slot configuration so `skillful` only affects global and project skills.
14
31
 
15
32
  ## [0.3.8] - 2026-06-06
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-skillful",
3
- "version": "0.3.9",
3
+ "version": "0.3.12",
4
4
  "description": "Pi package with skill invocation and visibility improvements.",
5
5
  "type": "module",
6
6
  "exports": {
@@ -45,14 +45,15 @@
45
45
  "@earendil-works/pi-tui": "*"
46
46
  },
47
47
  "devDependencies": {
48
- "@earendil-works/pi-coding-agent": "^0.78.0",
49
- "@earendil-works/pi-tui": "^0.78.0",
50
- "@types/node": "^25.6.2",
48
+ "@earendil-works/pi-coding-agent": "^0.80.0",
49
+ "@earendil-works/pi-tui": "^0.80.0",
50
+ "@types/node": "^26.0.1",
51
51
  "typescript": "^6.0.3"
52
52
  },
53
53
  "scripts": {
54
54
  "check": "tsc --noEmit",
55
55
  "typecheck": "tsc --noEmit",
56
+ "test": "rm -rf .test-dist && tsc --noEmit false --outDir .test-dist && node --test tests/*.test.mjs",
56
57
  "pack:dry-run": "npm pack --dry-run"
57
58
  },
58
59
  "publishConfig": {
@@ -42,7 +42,7 @@ interface BoxLike {
42
42
  }
43
43
 
44
44
  interface InteractiveModeLike {
45
- chatContainer?: BoxLike;
45
+ loadedResourcesContainer?: BoxLike;
46
46
  showLoadedResources?: (options?: unknown) => void;
47
47
  session?: { resourceLoader?: { getSkills: () => { skills: Skill[]; diagnostics: unknown[] } } };
48
48
  sessionManager?: { getCwd?: () => string };
@@ -85,7 +85,7 @@ export default function skillVisibility(pi: ExtensionAPI) {
85
85
 
86
86
  pi.on("session_start", async (_event, ctx) => {
87
87
  store.theme = ctx.ui.theme;
88
- await pruneStaleHiddenSkills(pi, ctx.cwd);
88
+ await refreshHiddenSkillCache(ctx.cwd);
89
89
  });
90
90
 
91
91
  pi.on("before_agent_start", async (event, ctx) => {
@@ -148,25 +148,6 @@ export default function skillVisibility(pi: ExtensionAPI) {
148
148
  });
149
149
  }
150
150
 
151
- async function pruneStaleHiddenSkills(pi: ExtensionAPI, cwd: string): Promise<void> {
152
- const installedNames = new Set(getSkillItems(pi).map((s) => s.name));
153
- const scoped = await readScopedSkillfulSettings(cwd);
154
-
155
- await Promise.all(
156
- SCOPES.map(async (scope) => {
157
- const currentHidden = scoped[scope].hiddenSkills;
158
- const prunedHidden = currentHidden.filter((name) => installedNames.has(name));
159
- if (prunedHidden.length < currentHidden.length) {
160
- scoped[scope] = await writeHiddenSkills(scope, cwd, prunedHidden);
161
- }
162
- }),
163
- );
164
-
165
- const hidden = new Set(scoped.project.hiddenSkillsDefined ? scoped.project.hiddenSkills : scoped.global.hiddenSkills);
166
- store.hiddenSkillsByCwd.set(cwd, hidden);
167
- store.lastHiddenSkills = hidden;
168
- }
169
-
170
151
  async function refreshHiddenSkillCache(cwd: string): Promise<Set<string>> {
171
152
  const hidden = await readEffectiveHiddenSkills(cwd);
172
153
  store.hiddenSkillsByCwd.set(cwd, hidden);
@@ -202,7 +183,7 @@ function installStartupSkillListPatch(): void {
202
183
  return result;
203
184
  };
204
185
 
205
- const childrenBefore = this.chatContainer?.children.length ?? 0;
186
+ const childrenBefore = this.loadedResourcesContainer?.children.length ?? 0;
206
187
 
207
188
  try {
208
189
  original.call(this, options);
@@ -210,17 +191,18 @@ function installStartupSkillListPatch(): void {
210
191
  loader.getSkills = originalGetSkills;
211
192
  }
212
193
 
213
- if (rawSkillNames.length === 0 || !cwd || !this.chatContainer) return;
194
+ if (rawSkillNames.length === 0 || !cwd || !this.loadedResourcesContainer) return;
214
195
 
215
- const children = this.chatContainer.children;
196
+ const children = this.loadedResourcesContainer.children;
216
197
  for (let i = childrenBefore; i < children.length; i++) {
217
198
  const child = children[i] as ExpandableTextLike | undefined;
218
199
  if (!child || typeof child.getCollapsedText !== "function") continue;
219
200
  const collapsed = child.getCollapsedText();
220
201
  if (!collapsed.includes("[Skills]")) continue;
221
202
 
222
- child.getCollapsedText = () => buildColorizedSkillList(rawSkillNames, store.lastHiddenSkills, store.theme);
223
- child.setText(child.getCollapsedText());
203
+ const colorized = buildColorizedSkillList(rawSkillNames, store.lastHiddenSkills, store.theme);
204
+ child.getCollapsedText = () => colorized;
205
+ child.setText(colorized);
224
206
  break;
225
207
  }
226
208
  };