Skip to content

Commit

Permalink
chore: update some docs on readme
Browse files Browse the repository at this point in the history
  • Loading branch information
inhere committed Oct 9, 2022
1 parent 9e8b419 commit 9bae072
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
[![Go Report Card](https://goreportcard.com/badge/github.com/gookit/config)](https://goreportcard.com/report/github.com/gookit/config)
[![Go Reference](https://pkg.go.dev/badge/github.com/gookit/config/v2.svg)](https://pkg.go.dev/github.com/gookit/config/v2)

Golang's application config manage tool library.
`config` - Simple, full-featured Go application configuration management tool library.

> **[中文说明](README.zh-CN.md)**
Expand All @@ -19,18 +19,18 @@ Golang's application config manage tool library.
- Other drivers are used on demand, not used will not be loaded into the application.
- Possibility to add custom driver for your specific format
- Support multi-file and multi-data loading
- Support loading configuration from os ENV
- Support for loading configuration from system ENV
- Support for loading configuration data from remote URLs
- Support for setting configuration data from command line arguments(`flags`)
- Support for setting configuration data from command line(`flags`)
- Support listen and fire events on config data changed.
- allow events: `set.value`, `set.data`, `load.data`, `clean.data`
- allow events: `set.value`, `set.data`, `load.data`, `clean.data`, `reload.data`
- Support data overlay and merge, automatically load by key when loading multiple copies of data
- Support for binding all or part of the configuration data to the structure
- Support init default value by struct tag `default:"def_value"`
- Support init default value from ENV `default:"${APP_ENV | dev}"`
- Support get sub value by path, like `map.key` `arr.2`
- Support get sub value by key-path, like `map.key` `arr.2`
- Support parse ENV name and allow with default value. like `envKey: ${SHELL|/bin/bash}` -> `envKey: /bin/zsh`
- Generic api `Get` `Int` `Uint` `Int64` `Float` `String` `Bool` `Ints` `IntMap` `Strings` `StringMap` ...
- Generic API: `Get` `Int` `Uint` `Int64` `Float` `String` `Bool` `Ints` `IntMap` `Strings` `StringMap` ...
- Complete unit test(code coverage > 95%)

## Only use INI
Expand Down
4 changes: 2 additions & 2 deletions README.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
[![Go Report Card](https://goreportcard.com/badge/github.com/gookit/config)](https://goreportcard.com/report/github.com/gookit/config)
[![Go Reference](https://pkg.go.dev/badge/github.com/gookit/config/v2.svg)](https://pkg.go.dev/github.com/gookit/config/v2)

简洁、功能完善的Golang应用程序配置管理工具库
`config` - 简洁、功能完善的 Go 应用程序配置管理工具库

> **[EN README](README.md)**
Expand All @@ -22,7 +22,7 @@
- 支持从远程 URL 加载配置数据
- 支持从命令行参数(`flags`)设置配置数据
- 支持在配置数据更改时触发事件
- 可用事件: `set.value`, `set.data`, `load.data`, `clean.data`
- 可用事件: `set.value`, `set.data`, `load.data`, `clean.data`, `reload.data`
- 支持数据覆盖合并,加载多份数据时将按key自动合并
- 支持将全部或部分配置数据绑定到结构体 `config.BindStruct("key", &s)`
- 支持通过结构体标签 `default` 解析并设置默认值. eg: `default:"def_value"`
Expand Down

0 comments on commit 9bae072

Please sign in to comment.