import { type McpRuntime } from './mcp-runtime.js'; import { type Stats } from 'node:fs'; type WindowsExecution = 'native' | 'windows-wsl'; interface McpConfigReplacement { configPath: string; destination: string; temporary: string; original: Stats | undefined; mode: number; } interface OpenMcpConfigReplacement extends McpConfigReplacement { fd: number; } /** Complete platform-specific policy selected before an atomic write begins. */ export interface McpConfigPersistenceStrategy { readonly kind: 'posix' | 'linux' | 'windows-native' | 'windows-wsl'; preflight(replacement: McpConfigReplacement): void; prepare(replacement: OpenMcpConfigReplacement): void; secure(replacement: OpenMcpConfigReplacement): void; publish(replacement: McpConfigReplacement): void; } /** Linux needs an implementation that preserves ACLs and extended attributes. */ export declare function linuxMetadataCopyCommand(): string; /** Resolve the OS runtime without searching the working directory or PATH. */ export declare function windowsPowerShellExecutable(location: WindowsExecution): string; /** Copy the destination file's Windows owner and DACL to a replacement inode. */ export declare function copyWindowsMcpConfigMetadata(source: string, destination: string, location: WindowsExecution): void; /** Atomically replace a Windows config while retaining a recoverable backup. */ export declare function replaceWindowsMcpConfigFile(source: string, destination: string, backup: string, location: WindowsExecution): void; /** Select persistence solely from the runtime and resolved physical destination. */ export declare function mcpConfigPersistenceStrategy(destination: string, runtime?: McpRuntime): McpConfigPersistenceStrategy; export {}; //# sourceMappingURL=mcp-config-metadata.d.ts.map