/**
 * jscpd integration — duplicate-code detection.
 *
 * The `jscpdProvider` is registered in `GLOBAL_CAPABILITIES.duplication`
 * (src/languages/capabilities/global.ts). jscpd runs once per repo with
 * a cross-language source-file pattern and respects the project's
 * `.gitignore` via the `--gitignore` flag — crucial on large repos,
 * jscpd without it walks into `node_modules` and OOMs.
 *
 * The source-file pattern is the union of every pack's
 * `sourceExtensions` (LP-recipe pattern, Phase 10i.0-LP). jscpd's
 * tokenizer is language-aware so a single union glob is safe; pack-
 * driven derivation keeps adding a new language to a one-line scaffold
 * change rather than a cross-cutting edit here.
 */
import type { CapabilityProvider } from '../../languages/capabilities/provider';
import type { DuplicationResult } from '../../languages/capabilities/types';
/**
 * Outcome union mirrors the other global wrappers (gitleaks, semgrep,
 * graphify). Collapses to `DuplicationResult | null` at the provider
 * level; keeping the `unavailable.reason` at this level lets internal
 * callers distinguish install-missing from parse-failure if needed.
 */
export type DuplicationGatherOutcome = {
    kind: 'success';
    envelope: DuplicationResult;
} | {
    kind: 'unavailable';
    reason: string;
};
/**
 * Single source of truth for the jscpd invocation. Consumed by
 * `jscpdProvider` (capability dispatcher).
 *
 * Failure-mode honesty: when jscpd doesn't produce a parseable
 * report, the returned `reason` distinguishes timeout, non-zero
 * exit (with first stderr line), or the rare true "no output"
 * case. Same shape as the semgrep gather — switched from execSync
 * to spawn-with-process-group so jscpd's worker pool (it splits
 * the scan across multiple Node workers internally) isn't killed
 * mid-run when execSync's wall-clock timer fires.
 */
export declare function gatherJscpdResult(cwd: string): Promise<DuplicationGatherOutcome>;
/**
 * Capability-shaped provider. Registered in
 * `src/languages/capabilities/global.ts:GLOBAL_CAPABILITIES.duplication`.
 */
export declare const jscpdProvider: CapabilityProvider<DuplicationResult> & {
    gatherOutcome(cwd: string): Promise<DuplicationGatherOutcome>;
};
//# sourceMappingURL=jscpd.d.ts.map