Support aliases for flags (#409)

Aliases are currently only supported for sub-commands, but they're
useful for flags as well. E.g., when migrating from an old flag name
to a new flag name, while still supporting the old value.
This commit is contained in:
Prashant Varanasi
2024-02-26 16:10:15 -08:00
committed by GitHub
parent 30e84613fe
commit fa9b636997
5 changed files with 50 additions and 4 deletions
+1
View File
@@ -397,6 +397,7 @@ type Flag struct {
Xor []string
PlaceHolder string
Envs []string
Aliases []string
Short rune
Hidden bool
Negated bool