- Module github.com/eslider/go-config with env/yaml/json/ini packages - internal: source, keymap, merge, structconv, bytesutil - cmd/envc: convert, get, merge - docs/asr ASR-0001..0008, README/CHANGELOG/AGENTS refresh - golangci-lint v2 config; tests + fixtures Co-authored-by: Cursor <cursoragent@cursor.com>
24 lines
919 B
Go
24 lines
919 B
Go
// Package config is the module root for go-config (import path
|
|
// github.com/eslider/go-config). Use the subpackages [env], [yaml], [json], and
|
|
// [ini] for format-specific codecs and the [cmd/envc] command for CLI
|
|
// conversion.
|
|
//
|
|
// Hero workflow (YAML + layered dotenv + process env):
|
|
//
|
|
// yamlCfg := yaml.New(yaml.WithURL("https://example.com/config.yaml"))
|
|
// envCfg := env.New(
|
|
// env.WithFile(".default.env"),
|
|
// env.WithFile(".env"),
|
|
// env.WithCurrentEnvironment(),
|
|
// )
|
|
// var svc MyService
|
|
// _ = yamlCfg.Unmarshal(&svc)
|
|
// _ = envCfg.Unmarshal(&svc)
|
|
//
|
|
// [cmd/envc]: https://pkg.go.dev/github.com/eslider/go-config/cmd/envc
|
|
// [env]: https://pkg.go.dev/github.com/eslider/go-config/env
|
|
// [yaml]: https://pkg.go.dev/github.com/eslider/go-config/yaml
|
|
// [json]: https://pkg.go.dev/github.com/eslider/go-config/json
|
|
// [ini]: https://pkg.go.dev/github.com/eslider/go-config/ini
|
|
package config
|