config

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckConfig

func CheckConfig()

CheckConfig checks if the config file exists

func CreateConfig

func CreateConfig()

CreateConfig creates a new config file

func RemoveConfig

func RemoveConfig()

func StartConfigEdit

func StartConfigEdit(conf Config)

func UserConf

func UserConf() string

UserConf returns the user config directory

func WriteConfig

func WriteConfig(f *os.File, conf Config)

Types

type Config

type Config struct {
	ConfVersion   string `json:"version"`
	DefaultSolver string `json:"default_solver"`
	FormID        string `json:"formID"`
	Ical_save     bool   `json:"ical_save"`
	CsvSave       bool   `json:"csv_save"`
	DefaultSorter string `json:"default_sorter"`
}

func GetConfigFile

func GetConfigFile(testing ...string) (Config, error)

parse json with golang https://tutorialedge.net/golang/parsing-json-with-golang/

Jump to

Keyboard shortcuts

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