dry-ts
Version:
Find candidate duplicate TypeScript code by comparing normalized AST structure.
72 lines (71 loc) • 2.65 kB
TypeScript
import type { ConfigOptions } from "./Config.js";
import { type OutputFormat } from "./types.js";
export declare const PROFILE_NAMES: readonly string[];
export interface OptionsInput {
readonly paths?: readonly string[];
readonly threshold?: number;
readonly minLines?: number;
readonly minNodes?: number;
readonly minLocations?: number;
readonly format?: OutputFormat;
readonly help?: boolean;
readonly failOnDuplicates?: boolean;
readonly respectGitignore?: boolean;
readonly changedFrom?: string;
readonly changed?: readonly string[];
readonly explainChanged?: boolean;
readonly onlyNew?: boolean;
readonly excludeKinds?: readonly string[];
readonly minDistinctKinds?: number;
readonly exclude?: readonly string[];
readonly excludeTaggedTemplates?: boolean;
readonly excludeTests?: boolean;
readonly counterparts?: boolean;
}
export interface ResolvedOptions {
readonly paths: readonly string[];
readonly threshold: number;
readonly minLines: number;
readonly minNodes: number;
readonly format: OutputFormat;
readonly help: boolean;
readonly failOnDuplicates: boolean;
readonly respectGitignore: boolean;
readonly minLocations: number;
readonly changedFrom: string | undefined;
readonly changed: readonly string[];
readonly explainChanged: boolean;
readonly onlyNew: boolean;
readonly excludeKinds: readonly string[];
readonly minDistinctKinds: number;
readonly exclude: readonly string[];
readonly excludeTaggedTemplates: boolean;
readonly excludeTests: boolean;
readonly counterparts: boolean;
}
export declare class Options {
readonly paths: readonly string[];
readonly threshold: number;
readonly minLines: number;
readonly minNodes: number;
readonly format: OutputFormat;
readonly help: boolean;
readonly failOnDuplicates: boolean;
readonly respectGitignore: boolean;
readonly minLocations: number;
readonly changedFrom: string | undefined;
readonly changed: readonly string[];
readonly explainChanged: boolean;
readonly onlyNew: boolean;
readonly excludeKinds: readonly string[];
readonly minDistinctKinds: number;
readonly exclude: readonly string[];
readonly excludeTaggedTemplates: boolean;
readonly excludeTests: boolean;
readonly counterparts: boolean;
constructor(resolved: ResolvedOptions);
static defaults(): Options;
static from(input?: OptionsInput): Options;
static parse(...args: string[]): Options;
static fromCli(args: readonly string[], config?: ConfigOptions): Options;
}