import { RULES_CONFIG_DIRECTORY_NAME, SKILLS_CONFIG_DIRECTORY_NAME, WORKFLOWS_CONFIG_DIRECTORY_NAME } from "@cline/shared/storage"; import { type UnifiedConfigDefinition, UnifiedConfigFileWatcher, type UnifiedConfigWatcherEvent } from "./unified-config-file-watcher"; export { RULES_CONFIG_DIRECTORY_NAME, SKILLS_CONFIG_DIRECTORY_NAME, WORKFLOWS_CONFIG_DIRECTORY_NAME, }; export interface ParseMarkdownFrontmatterResult { data: Record; body: string; hadFrontmatter: boolean; parseError?: string; } export interface SkillConfig { name: string; description?: string; disabled?: boolean; instructions: string; frontmatter: Record; } export interface RuleConfig { name: string; disabled?: boolean; instructions: string; frontmatter: Record; } export interface WorkflowConfig { name: string; disabled?: boolean; description?: string; instructions: string; frontmatter: Record; } export type UserInstructionConfigType = "skill" | "rule" | "workflow"; export type UserInstructionConfig = SkillConfig | RuleConfig | WorkflowConfig; export type UserInstructionConfigWatcher = UnifiedConfigFileWatcher; export type UserInstructionConfigWatcherEvent = UnifiedConfigWatcherEvent; export interface CreateInstructionWatcherOptions { debounceMs?: number; emitParseErrors?: boolean; } export interface CreateSkillsConfigDefinitionOptions { directories?: ReadonlyArray; workspacePath?: string; includePluginSkills?: boolean; pluginSkillDirectories?: ReadonlyArray; pluginPaths?: ReadonlyArray; cwd?: string; } export interface CreateRulesConfigDefinitionOptions { directories?: ReadonlyArray; workspacePath?: string; } export interface CreateWorkflowsConfigDefinitionOptions { directories?: ReadonlyArray; workspacePath?: string; } export declare function parseSkillConfigFromMarkdown(content: string, fallbackName: string): SkillConfig; export declare function parseRuleConfigFromMarkdown(content: string, fallbackName: string): RuleConfig; export declare function parseWorkflowConfigFromMarkdown(content: string, fallbackName: string): WorkflowConfig; export declare function resolveSkillsConfigSearchPaths(workspacePath?: string): string[]; export declare function resolveRulesConfigSearchPaths(workspacePath?: string): string[]; export declare function resolveWorkflowsConfigSearchPaths(workspacePath?: string): string[]; export declare function createSkillsConfigDefinition(options?: CreateSkillsConfigDefinitionOptions): UnifiedConfigDefinition<"skill", SkillConfig>; export declare function createRulesConfigDefinition(options?: CreateRulesConfigDefinitionOptions): UnifiedConfigDefinition<"rule", RuleConfig>; export declare function createWorkflowsConfigDefinition(options?: CreateWorkflowsConfigDefinitionOptions): UnifiedConfigDefinition<"workflow", WorkflowConfig>; export interface CreateUserInstructionConfigWatcherOptions extends CreateInstructionWatcherOptions { skills?: CreateSkillsConfigDefinitionOptions; rules?: CreateRulesConfigDefinitionOptions; workflows?: CreateWorkflowsConfigDefinitionOptions; } export declare function createUserInstructionConfigWatcher(options?: CreateUserInstructionConfigWatcherOptions): UserInstructionConfigWatcher;