UNPKG

cmpstr-cli

Version:

Simple CLI wrapper for the CmpStr package to normalize and compare strings directly via terminal

24 lines (23 loc) 796 B
/** * @fileoverview * Diff command for CmpStr CLI. * * Finds and marks the differences between two texts, supporting various * diff modes and options. Outputs either a colored CLI diff, ASCII diff * for files, or a structured diff in verbose mode. * * @author Paul Köhler (komed3) * @license MIT */ import { type Command } from 'commander'; /** * Finds and marks the differences between two texts. * * @async * @param {string} a - The original text or file path. * @param {string} b - The modified text or file path. * @param {Record<string, any>} [opt] - Diff options. * @param {Command} cmd - The Commander command instance. * @returns {Promise<void>} */ export declare function diff(a: string, b: string, opt: Record<string, any> | undefined, cmd: Command): Promise<void>;