/** * mergeGitignore computes the .gitignore content `diablo init` should write, * idempotently. diablo creates machine-managed runtime dirs (.diablo/, * .worktrees/) that must never be committed in ANY project it scaffolds, so * those always land in a clearly-marked managed block. * * Pure (string in, string-or-null out) so the merge rules are unit-tested * directly; the adapter only reads the existing file and writes the result. */ /** * Computes the .gitignore content for `diablo init`. * * @param existing the current .gitignore content, or null if none exists. * @param greenfield true when the repo has no commits yet — a fresh project, * where diablo also seeds common ignores (node_modules/, dist/, .env) since * nothing has established them. Brownfield repos keep their own conventions; * diablo only contributes its runtime dirs. * @returns the content to write, or null when nothing needs to change (the * managed block is already present). */ export declare function mergeGitignore(existing: string | null, greenfield: boolean): string | null;