env

package
v2.3.2 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2022 License: MIT Imports: 1 Imported by: 1

Documentation

Index

Constants

View Source
const (
	EnvNamePrefix    = "TGC_"       // Tron-Go-Common
	EnvNamePrefixEnv = "TGC_PREFIX" // Env var to override "TGC_"

	EnvDev     = "dev"
	EnvStaging = "staging"
	EnvProd    = "production"
)

Variables

View Source
var (
	LogFile = ""
)

Functions

func GetCurrentEnv

func GetCurrentEnv() string

func GetEnv

func GetEnv(name string) (string, string)

GetEnv checks the prefix settings and returns the correct application- specific environment variable value

func IsDev

func IsDev() bool

func IsProd

func IsProd() bool

func IsStaging

func IsStaging() bool

func SetCurrentEnv

func SetCurrentEnv(env string)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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