feat(coding-agent): add pi config TUI to manage resources

Adds a new 'pi config' command with a TUI to list and toggle package
resources (extensions, skills, prompts, themes).

- Displays resources grouped by source (packages, user, project)
- Subgroups by resource type (Extensions, Skills, Prompts, Themes)
- Toggle enabled/disabled state with space
- Filter resources by typing
- Supports +pattern for force-include, !pattern for exclude
- Properly reads exclusion patterns from settings.json

fixes #938
This commit is contained in:
Mario Zechner 2026-01-25 03:12:21 +01:00
parent ef5149fdf6
commit 150128fd2c
5 changed files with 977 additions and 0 deletions

View file

@ -487,6 +487,13 @@ export class SettingsManager {
this.save();
}
setProjectSkillPaths(paths: string[]): void {
const projectSettings = this.loadProjectSettings();
projectSettings.skills = paths;
this.saveProjectSettings(projectSettings);
this.settings = deepMergeSettings(this.globalSettings, projectSettings);
}
getPromptTemplatePaths(): string[] {
return [...(this.settings.prompts ?? [])];
}
@ -496,6 +503,13 @@ export class SettingsManager {
this.save();
}
setProjectPromptTemplatePaths(paths: string[]): void {
const projectSettings = this.loadProjectSettings();
projectSettings.prompts = paths;
this.saveProjectSettings(projectSettings);
this.settings = deepMergeSettings(this.globalSettings, projectSettings);
}
getThemePaths(): string[] {
return [...(this.settings.themes ?? [])];
}
@ -505,6 +519,13 @@ export class SettingsManager {
this.save();
}
setProjectThemePaths(paths: string[]): void {
const projectSettings = this.loadProjectSettings();
projectSettings.themes = paths;
this.saveProjectSettings(projectSettings);
this.settings = deepMergeSettings(this.globalSettings, projectSettings);
}
getEnableSkillCommands(): boolean {
return this.settings.enableSkillCommands ?? true;
}