UNPKG

markmv

Version:

TypeScript CLI for markdown file operations with intelligent link refactoring

57 lines 1.81 kB
/** * Configuration options for move command operations. * * Controls the behavior of the move command including preview mode and output verbosity. * * @category Commands */ export interface MoveOptions { /** Perform a dry run without making actual changes */ dryRun?: boolean; /** Enable verbose output with detailed progress information */ verbose?: boolean; } /** * Execute the move command to relocate markdown files with intelligent link refactoring. * * This is the main entry point for the move command functionality. It supports: * * - Single file moves to a new location * - Multiple file moves to a target directory * - Glob pattern expansion for source files * - Dry run mode for previewing changes * - Comprehensive link integrity validation and updates * * The command automatically discovers and updates all cross-references to moved files throughout * the project, ensuring that no links are broken during the move operation. * * @category Commands * * @example * Single file move * ```typescript * await moveCommand(['docs/old.md', 'docs/new.md'], { verbose: true }); * ``` * * @example * Multiple files to directory * ```typescript * await moveCommand(['*.md', 'archive/'], { dryRun: true }); * ``` * * @example * Glob pattern with dry run * ```typescript * await moveCommand(['docs/**\/*.md', 'backup/'], { * dryRun: true, * verbose: true * }); * ``` * * @param sources - Array containing source patterns and destination (last element) * @param options - Configuration options for the move operation * * @throws Will exit the process with code 1 if the operation fails */ export declare function moveCommand(sources: string[], options: MoveOptions): Promise<void>; //# sourceMappingURL=move.d.ts.map