config

package module
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2021 License: MIT Imports: 6 Imported by: 0

README

config

Config wrapper library based on viper.

Installing

go get github.com/alexferl/x/configs

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultConfig = &Config{
		AppName:      "app",
		EnvName:      "dev",
		EnvVarPrefix: "app",
		Logging:      xlog.DefaultConfig,
	}
)

Functions

This section is empty.

Types

type Config

type Config struct {
	AppName      string
	EnvName      string
	EnvVarPrefix string
	Logging      *xlog.Config
}

Config holds all global configuration for our program

func New

func New() *Config

New creates a Config instance

func (*Config) BindFlags

func (c *Config) BindFlags()

BindFlags normalizes and parses the command line flags

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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