feat: support env tag in config (#2577)
* feat: support env tag in config * chore: add more tests * chore: add more tests, add stringx.Join * fix: test fail * chore: remove print code * chore: rename variable
This commit is contained in:
@@ -13,6 +13,7 @@ type (
|
||||
Optional bool
|
||||
Options []string
|
||||
Default string
|
||||
EnvVar string
|
||||
Range *numberRange
|
||||
}
|
||||
|
||||
@@ -106,5 +107,6 @@ func (o *fieldOptions) toOptionsWithContext(key string, m Valuer, fullName strin
|
||||
Optional: optional,
|
||||
Options: o.Options,
|
||||
Default: o.Default,
|
||||
EnvVar: o.EnvVar,
|
||||
}, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user