Skip to content

Commit

Permalink
refactor: support string value alias,but flag env not support now
Browse files Browse the repository at this point in the history
  • Loading branch information
hui.wang committed Jan 20, 2022
1 parent d4b089d commit 65bd505
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
1 change: 1 addition & 0 deletions tests/conf.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ func ConfigOptionDeclareWithDefault() interface{} {
},
"ProcessCount": int8(1),
"MaxUint64": uint64(0),
"MaxInt": int(0),
"Int8": int8(1),
"TimeDurations": []time.Duration([]time.Duration{time.Second, time.Second}), // @MethodComment(延迟队列)
"DefaultEmptyMap": map[string]int{},
Expand Down
13 changes: 13 additions & 0 deletions tests/gen_config_optiongen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion tests/main/c1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,5 @@ redis_as_pointer:
redis:
redis_address: 127.0.0.1:6638
process_count: runtime.NumCPU
max_uint64: math.MaxUint64
max_uint64: math.MaxUint64
max_int: math.MaxInt

0 comments on commit 65bd505

Please sign in to comment.