/** * Path utilities for takt configuration * * This module provides pure path utilities without UI dependencies. * For initialization with language selection, use initialization.ts. */ import type { Language } from '../../core/models/index.js'; import type { FacetKind } from 'faceted-prompting'; /** Facet types used in layer resolution */ export type { FacetKind as FacetType } from 'faceted-prompting'; type FacetType = FacetKind; /** Run a synchronous historical-source load without consulting current global config. */ export declare function withGlobalConfigDirOverride(configDir: string, action: () => T): T; /** Get takt global config directory (~/.takt or TAKT_CONFIG_DIR) */ export declare function getGlobalConfigDir(): string; /** Get takt global personas directory (~/.takt/personas) */ export declare function getGlobalPersonasDir(): string; /** Get takt global workflows directory (~/.takt/workflows) */ export declare function getGlobalWorkflowsDir(): string; /** Get takt global schemas directory (~/.takt/schemas) */ export declare function getGlobalSchemasDir(): string; export declare function getGlobalProviderOptionsDir(): string; export declare function getGlobalStepsDir(): string; export declare function getGlobalCompanionsDir(): string; /** Get takt global facet-pools directory (~/.takt/facet-pools) */ export declare function getGlobalFacetPoolsDir(): string; /** Get takt global logs directory */ export declare function getGlobalLogsDir(): string; /** Get takt global config file path */ export declare function getGlobalConfigPath(): string; /** Get builtin workflows directory (builtins/{lang}/workflows) */ export declare function getBuiltinWorkflowsDir(lang: Language): string; export declare function getBuiltinProviderOptionsDir(lang: Language): string; export declare function getBuiltinLanguageStepsDir(lang: Language): string; /** Legacy shared step-fragment root used before fragments became language-scoped. */ export declare function getBuiltinSharedStepsDir(): string; /** Get builtin language-scoped facet-pools directory (builtins/{lang}/facet-pools) */ export declare function getBuiltinLanguageFacetPoolsDir(lang: Language): string; /** Get builtin language resources root (builtins/{lang}). Facet-pool owned facets live under builtins/{lang}/facets/, outside facet-pools/. */ export declare function getBuiltinLanguageResourcesDir(lang: Language): string; export declare function getBuiltinCompanionsDir(lang: Language): string; /** Get builtin shared facet-pools directory (builtins/facet-pools) */ export declare function getBuiltinSharedFacetPoolsDir(): string; export declare function isBuiltinWorkflowPath(filePath: string): boolean; /** Get builtin personas directory (builtins/{lang}/facets/personas) */ export declare function getBuiltinPersonasDir(lang: Language): string; /** Get project takt config directory (.takt in project) */ export declare function getProjectConfigDir(projectDir: string): string; /** Get project workflows directory (.takt/workflows in project) */ export declare function getProjectWorkflowsDir(projectDir: string): string; /** Get project schemas directory (.takt/schemas in project) */ export declare function getProjectSchemasDir(projectDir: string): string; export declare function getProjectProviderOptionsDir(projectDir: string): string; export declare function getProjectStepsDir(projectDir: string): string; export declare function getProjectCompanionsDir(projectDir: string): string; /** Get project facet-pools directory (.takt/facet-pools in project) */ export declare function getProjectFacetPoolsDir(projectDir: string): string; /** Get project config file path */ export declare function getProjectConfigPath(projectDir: string): string; /** Return the resolved path when global and project configuration directories collide. */ export declare function getConfigDirCollision(projectDir: string): string | undefined; /** Get project tasks directory */ export declare function getProjectTasksDir(projectDir: string): string; /** Get project completed tasks directory */ export declare function getProjectCompletedDir(projectDir: string): string; /** Get project logs directory */ export declare function getProjectLogsDir(projectDir: string): string; /** Ensure a directory exists, create if not */ export declare function ensureDir(dirPath: string): void; /** Get project facet directory (.takt/facets/{facetType} in project) */ export declare function getProjectFacetDir(projectDir: string, facetType: FacetType): string; /** Get global facet directory (~/.takt/facets/{facetType}) */ export declare function getGlobalFacetDir(facetType: FacetType): string; /** Get builtin facet directory (builtins/{lang}/facets/{facetType}) */ export declare function getBuiltinFacetDir(lang: Language, facetType: FacetType): string; /** Get repertoire directory (~/.takt/repertoire/) */ export declare function getRepertoireDir(): string; /** Get repertoire package directory (~/.takt/repertoire/@{owner}/{repo}/) */ export declare function getRepertoirePackageDir(owner: string, repo: string): string; /** * Get repertoire facet directory. * * Defaults to the global repertoire dir when repertoireDir is not specified. * Pass repertoireDir explicitly when resolving facets within a custom repertoire root * (e.g. the package-local resolution layer). */ export declare function getRepertoireFacetDir(owner: string, repo: string, facetType: FacetType, repertoireDir?: string): string; export declare function getRepertoireProviderOptionsDir(owner: string, repo: string, repertoireDir?: string): string; export declare function getRepertoireStepsDir(owner: string, repo: string, repertoireDir?: string): string; /** Get repertoire facet-pools directory (~/.takt/repertoire/@{owner}/{repo}/facet-pools) */ export declare function getRepertoireFacetPoolsDir(owner: string, repo: string, repertoireDir?: string): string; /** Validate path is safe (no directory traversal) */ export declare function isPathSafe(basePath: string, targetPath: string): boolean; export { loadProjectConfig, saveProjectConfig, updateProjectConfig, type ProjectLocalConfig, } from './project/projectConfig.js'; export { isVerboseMode, } from './project/resolvedSettings.js'; export { writeFileAtomic, getInputHistoryPath, MAX_INPUT_HISTORY, loadInputHistory, saveInputHistory, addToInputHistory, type PersonaSessionData, getPersonaSessionsPath, loadPersonaSessions, savePersonaSessions, updatePersonaSession, clearPersonaSessions, getWorktreeSessionsDir, encodeWorktreePath, getWorktreeSessionPath, loadWorktreeSessions, updateWorktreeSession, } from './project/sessionStore.js'; //# sourceMappingURL=paths.d.ts.map