config

module
v1.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 23, 2023 License: MIT

README

github.com/aellwein/config

What is it?

This Go module provides a configuration file management defined by stable, versioned Cfg interface to be used across your Go files without a coupling to the actual implementation.

The Cfg interface mimics the viper interface and also uses it as its default implementation.

Implementation can be exchanged on demand without doing modification to your app's code.

Usage

The usage is very simple. Refer to example.go file to get an idea on how to use it.

Bonus

Config object can be passed via context.Context interface.

This is useful, for example, if you work with commandline parsers like spf13/cobra or urfave/cli.

License

MIT License

Directories

Path Synopsis
v1

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL