You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Do not use *_DEFAULT as a suffix to the enums, because "default" is
overloaded. The following are two examples:
(1) "Default" can mean using the "default" values that are hardcoded
in trailer.c as
default_conf_info.where = WHERE_END;
default_conf_info.if_exists = EXISTS_ADD_IF_DIFFERENT_NEIGHBOR;
default_conf_info.if_missing = MISSING_ADD;
in ensure_configured(), and reflected in the manpage for
interpret-trailers. These values are used if no trailer.*
configurations are defined in .gitconfig.
(2) "Default" can also mean the default trailer values that can be
configured in .gitconfig, under "trailer.where", "trailer.ifexists",
or "trailer.ifmissing" (or their trailer.<token>.* counterparts).
These configured values are used by default if no command line
arguments are provided.
In addition, the *_DEFAULT values are chosen when the user supplies the
"--no-where", "--no-if-exists", or "--no-if-missing" flags on the
command line. These flags are used to go back to the behavior specified
by the relevant _configuration_ values, if any. So instead of using
"*_DEFAULT", use "*_CONFIG" because this avoids the ambiguity.
Signed-off-by: Linus Arver <linusa@google.com>
0 commit comments