config

package
v0.0.0-...-2d51b20 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const DEFAULT_CONFIG_DIR_NAME string = ".cde"
View Source
const DEFAULT_CONFIG_FILE_NAME string = "config.yml"

Variables

This section is empty.

Functions

func GetConfigDirPath

func GetConfigDirPath() (string, error)

func GetConfigFilePath

func GetConfigFilePath() (string, error)

func Print

func Print(c Config) string

func PrintDirs

func PrintDirs(c Config) string

func WriteConfig

func WriteConfig(filePath string, data Config) error

Types

type Config

type Config struct {
	UpdatedAt string    `yaml:"updatedAt"`
	Dirs      []dir.Dir `yaml:"dirs"`
}

func Init

func Init() (Config, error)

func ReadConfig

func ReadConfig(filePath string) (Config, error)

func (Config) GetDir

func (c Config) GetDir(name string) dir.Dir

Jump to

Keyboard shortcuts

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