DuplicatePolicy
How repeated CLI occurrences of a singleton flag combine.
'last'— last occurrence wins (matches historic behavior)'first'— first occurrence wins; later ones parse but are ignored'error'— a second occurrence is aParseError(DUPLICATE_FLAG)
Applies to CLI token occurrences only — env/config/prompt/default resolution keeps its precedence semantics and never raises duplicates. Occurrences are counted per logical flag: aliases and the negated spelling all count toward the same flag.
- Import:
@kjanat/dreamcli - Export kind: type
- Declared in:
src/core/schema/flag.ts - Source link:
src/core/schema/flag.ts:231
Signatures
ts
type DuplicatePolicy = "last" | "first" | "error";