env

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2022 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ConfigName = "config"
	ConfigType = "json"
)

Variables

This section is empty.

Functions

func BinaryDir

func BinaryDir() string

func ConfigDir

func ConfigDir() string

func ConfigFile

func ConfigFile() string

func Linux_Desktop

func Linux_Desktop() string

func Linux_StartupDir

func Linux_StartupDir() string

func LogFile

func LogFile() string

func UpperName

func UpperName(name string) string

func UserHomeDir

func UserHomeDir() string

func Win_Script

func Win_Script() string

func Win_StartupDir

func Win_StartupDir() string

func WriteLog

func WriteLog(str string)

Types

type App

type App struct {
	Enabled bool `mapstructure:"enabled"`
	//	Name    string `mapstructure:"name"`
	Path string `mapstructure:"path"`
}

type Config

type Config struct {
	Enabled bool `mapstructure:"enabled"`
	Delay   int  `mapstructure:"delay"`
}

type Configuration

type Configuration struct {
	Conf Config         `mapstructure:"config"`
	Apps map[string]App `mapstructure:"apps"`
}

func LoadConfig

func LoadConfig() (config Configuration, err error)

func (*Configuration) WriteConfig

func (conf *Configuration) WriteConfig() (err error)

type Startup

type Startup struct {
	Dir     string
	File    string
	Content string
}

Jump to

Keyboard shortcuts

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