import { SkillRegistryEntry, IDependencyInstaller } from '../types'; import { SkillRegistry } from '../registry/skill-registry'; export interface SkillInstallerConfig { /** Directory where installed skill packages are stored */ skillsDir: string; /** Custom dependency installers (defaults to built-in npm + pip) */ dependencyInstallers?: IDependencyInstaller[]; } /** * Handles the full lifecycle of skill installation and uninstallation. * * Install flow (§8.1): * 1. Ingest artifact → validate path safety → extract to isolated directory * 2. Locate package root (contains SKILL.md) * 3. Validate frontmatter * 4. Validate name matches directory name * 5. Install dependencies (npm/pip) * 6. Parse manifest.json tools * 7. Write to registry and register tools * * Uninstall flow (§8.2): * 1. Unregister tools → stop related runtime * 2. Delete package directory and artifacts * 3. Update registry */ export declare class SkillInstaller { private readonly config; private readonly registry; private readonly dependencyManager; constructor(config: SkillInstallerConfig, registry: SkillRegistry); /** * Install a skill from a source path (directory or zip archive). */ install(source: string): Promise; /** * Uninstall a skill by name. */ uninstall(name: string): Promise; /** * Stage a skill source (directory or zip) into a temporary directory * under the skills storage for preview/inspection. */ stageToTemp(source: string): string; /** * Install a skill from a previously staged temp directory. * Renames the temp dir to the final skill name directory. */ installFromStaged(tempDir: string, options?: { fallbackName?: string; }): Promise; /** * Clean up a staged temp directory (e.g. user decides not to install). */ cleanupTemp(tempDir: string): void; /** Copy a directory-based skill into the skills storage */ private installFromDirectory; /** Extract a zip-based skill into the skills storage */ private installFromZip; /** Remove a directory tree */ private cleanupDir; } //# sourceMappingURL=skill-installer.d.ts.map