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
It's not common to deprecate fields to remove them in the next release or move them to some other place. It would be nice to have support for it in aconfig. Maybe something like
type MyConfig struct {
Hostname int `default:"xyz.internal" usage:"hostname" deprecated:"this will be gone in the next release, the internet is a dangerous place, localhost will be a default"`
}
and have a function to collect all deprecations if the value is set.
The text was updated successfully, but these errors were encountered:
Sure, I'd like to collect all the deprecations in something like
type Deprecation struct {
Flag string
Env string
YamlKey string
Message string
}
So I can collect []Deprecation and print them for user. I want to bother the user with message only if they set (via env/flag/yaml) the deprecated config.
It's not common to deprecate fields to remove them in the next release or move them to some other place. It would be nice to have support for it in aconfig. Maybe something like
and have a function to collect all deprecations if the value is set.
The text was updated successfully, but these errors were encountered: