config

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DfPath    string              `toml:"dotfiles_path"`
	Log       bool                `toml:"log"`
	LogPath   string              `toml:"log_path"`
	Dotfiles  []Dotfile           `toml:"dotfile"`
	Variables map[string]Variable `toml:"variable"`
}

Config is user configuration

func LoadConfig

func LoadConfig(configPath string) *Config

type Dotfile

type Dotfile struct {
	Name  string `toml:"name"`
	Steps []Step `toml:"step"`
}

type Step

type Step struct {
	Name   string `toml:"name"`
	Force  bool   `toml:"force"`
	Backup bool   `toml:"backup"`
	Src    string `toml:"src"`
	Target string `toml:"target"`
	Type   string `toml:"type"`
	Cmd    string `toml:"cmd"`
}

type Variable

type Variable struct {
	Var string `toml:"var"`
}

func (Variable) String

func (v Variable) String() string

Jump to

Keyboard shortcuts

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