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
Recent functionality was added around the gcfg:"extra_values" tag which allows extra fields set on the configuration file to be read and set, even if they aren't statically defined.
There a couple of things worth nothing with the gcfg:"extra_values" tag that are worth investigating:
The original library already supported the gcfg tag which allowed for the variable name in the configuration file to differ from the actual Go struct field. ie. "BuildFilename string gcfg:"anything"" would map the anything variable in the configuration file to the BuildFilename struct field. This means that gcfg:"extra_values" is also a valid variable rename case.
If a field is set as "MyField map[string]string gcfg:"extra_values"", what happens if there's a corresponding myfield variable set in the configuration file?
These are edge cases that I bumped into when working on separate tickets.
The text was updated successfully, but these errors were encountered:
Recent functionality was added around the
gcfg:"extra_values"
tag which allows extra fields set on the configuration file to be read and set, even if they aren't statically defined.There a couple of things worth nothing with the
gcfg:"extra_values"
tag that are worth investigating:gcfg
tag which allowed for the variable name in the configuration file to differ from the actual Go struct field. ie. "BuildFilename stringgcfg:"anything"
" would map theanything
variable in the configuration file to theBuildFilename
struct field. This means thatgcfg:"extra_values"
is also a valid variable rename case.gcfg:"extra_values"
", what happens if there's a correspondingmyfield
variable set in the configuration file?These are edge cases that I bumped into when working on separate tickets.
The text was updated successfully, but these errors were encountered: