conf

package module
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2024 License: MIT Imports: 10 Imported by: 0

README

conf

Conf utility urfave/cli as cmd

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Cmd = &cli.Command{
	Name:  "conf",
	Usage: "manage configuration file",
	Subcommands: []*cli.Command{
		initCmd,
		editCmd,
		dataCmd,
		pathCmd,
	},
}

Functions

func DirPath added in v0.1.1

func DirPath() string

DirPath returns config dir.

func Init

func Init() error

Init initializes the configuration directory for the current user and given application name. The directory is completely removed and new configuration file(s) are created.

func LoadConfig

func LoadConfig(out interface{}) error

LoadConfig reads and decodes config file content into 'out'.

func SetDefault

func SetDefault(in interface{})

SetDefault sets the default config.

func SoftInit

func SoftInit() error

SoftInit calls Init if config file does not exists.

Types

This section is empty.

Jump to

Keyboard shortcuts

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