import { expandAbbreviations, type LongOptionAlias, } from '../abbrev.ts'; //region Commit long-option abbreviation tables (git accepts unambiguous prefixes) /** Aliases for `--include`, generated by {@link expandAbbreviations}. Requires `--inc` because `--in` is ambiguous with `--interactive` and `--inter-hunk-context` (verified against git 2.54). */ export const INCLUDE_ALIASES: readonly [ LongOptionAlias, ...LongOptionAlias[], ] = expandAbbreviations({ longOption: '--include', minStemLength: 3, },); /** Aliases for `--dry-run`, generated by {@link expandAbbreviations}. Requires `--dr` because `--d` is ambiguous with `--date` (verified against git 2.54). */ export const DRY_RUN_COMMIT_ALIASES: readonly [ LongOptionAlias, ...LongOptionAlias[], ] = expandAbbreviations({ longOption: '--dry-run', minStemLength: 2, },); /** Aliases for `--short`, generated by {@link expandAbbreviations}, which git documents as implying `--dry-run`. Requires `--sh` because `--s` is ambiguous with `--status`, `--signoff`, and `--squash` (verified against git 2.54). */ export const SHORT_ALIASES: readonly [ LongOptionAlias, ...LongOptionAlias[], ] = expandAbbreviations({ longOption: '--short', minStemLength: 2, },); /** Aliases for `--porcelain`, generated by {@link expandAbbreviations}, which git documents as implying `--dry-run`. Requires `--por` because `--po` is ambiguous with `--no-no-post-rewrite` (verified against git 2.54). */ export const PORCELAIN_ALIASES: readonly [ LongOptionAlias, ...LongOptionAlias[], ] = expandAbbreviations({ longOption: '--porcelain', minStemLength: 3, },); /** Aliases for `--long`, generated by {@link expandAbbreviations}, which git documents as implying `--dry-run`. `--l` is already unambiguous (verified against git 2.54). */ export const LONG_ALIASES: readonly [ LongOptionAlias, ...LongOptionAlias[], ] = expandAbbreviations({ longOption: '--long', },); /** Aliases for `--null` (long form of `-z`), generated by {@link expandAbbreviations}, which git documents as implying `--dry-run`. Requires `--nu` because `--n` is ambiguous with the `--no-*` negation family (verified against git 2.54). */ export const NULL_ALIASES: readonly [ LongOptionAlias, ...LongOptionAlias[], ] = expandAbbreviations({ longOption: '--null', minStemLength: 2, },); //endregion Commit long-option abbreviation tables