/** One `-c key=value` (or `--config-env=key=ENVVAR`, whose value is the variable name). */ export type GitConfigOverride = { key: string; value: string; }; export type GitInvocation = { /** Subcommand arguments, unquoted, up to the end of the command segment. */ args: string[]; /** `-c key=value` pairs in order, with each key as written. */ configOverrides: GitConfigOverride[]; /** Every global option word skipped to reach the subcommand, as written (`['-C', '/x']`). */ globalOptions: string[]; /** The subcommand word, or undefined for a bare `git` or `git --version`. */ subcommand: string | undefined; }; /** * Each `git` the shell would run in command position: after a separator, env assignments, or a * wrapper (`env`, `sudo`, `xargs`, `timeout`, `nice`, ...). A `git` word in argument position * (`printf %s git`) is not an invocation. Global options are skipped to reach the subcommand and * `-c` pairs are collected. `$(...)` text and `bash -c` scripts are not read: feed those to * `extractShellCommandSubstitutions` / `extractShellCommandArguments` and call this on each. */ export declare function gitInvocations(command: string): GitInvocation[]; /** True when the invocation sets `key` with `-c`. Keys compare case-insensitively. */ export declare function overridesConfig(invocation: GitInvocation, key: string): boolean;