Documentation ¶
Index ¶
Constants ¶
View Source
const ( // ModeDev is the development mode ModeDev = "dev" // ModeProd is the production mode ModeProd = "prod" )
Variables ¶
View Source
var Mode = NewModeFlag(ModeDev, []string{ModeDev, ModeProd})
Mode is the environment mode
View Source
var (
NilModeFlagError = errors.New("mode flag cannot be nil")
)
Functions ¶
Types ¶
type Flag ¶ added in v0.7.0
type Flag struct {
// contains filtered or unexported fields
}
Flag is a custom flag type
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
Logger is the logger for the flag
func NewLogger ¶
func NewLogger(logger commonlogger.Logger) (*Logger, error)
NewLogger is the logger for the flag
func (*Logger) ModeFlagSet ¶
ModeFlagSet is the flag set for the mode
Click to show internal directories.
Click to hide internal directories.