Documentation
¶
Index ¶
- Variables
- func IsEmpty(name string) (bool, error)
- func Unlink(stateConfig *StateConfig) (err error)
- func WriteStatefile(stateConfig StateConfig) (err error)
- type Arg
- type Collection
- type CollectionOrPackages
- type Config
- type ConfigManager
- type Diff
- type Differ
- type IHandler
- type Packages
- type StateConfig
- type UsageHelper
Constants ¶
This section is empty.
Variables ¶
View Source
var ( CompletionUse string = "completion [bash|zsh|fish|powershell]" CompletionShort string = "Generate completion script" InstallUse string = "install [uri]" InstallShort string = "Installs dotfiles" InstallLong string = "" DiffUse string = "diff [collection]" DiffShort string = "Show changes between linked files and repository" DiffLong string = `Show changes between linked files and repository` InstallLocalPath string = path.Join(homeDir, ".local/share/dotfiles") InstallGlobalPath string = "/usr/share/dotfiles" DotfileConfig []string = []string{"dotfiles.yaml", "dotfiles.yml", "dotfile.yaml", "dotfile.yml"} StateConfigName string = "dotfiles.yaml" )
Functions ¶
func Unlink ¶
func Unlink(stateConfig *StateConfig) (err error)
func WriteStatefile ¶
func WriteStatefile(stateConfig StateConfig) (err error)
Types ¶
type Collection ¶
type CollectionOrPackages ¶
type CollectionOrPackages struct {
Collection Collection `yaml:"collection"`
Packages Packages `yaml:"packages"`
}
func (*CollectionOrPackages) UnmarshalYAML ¶
func (c *CollectionOrPackages) UnmarshalYAML(unmarshal func(interface{}) error) error
type Config ¶
type Config struct {
Collections map[string]CollectionOrPackages `yaml:"collections"`
}
type ConfigManager ¶
type ConfigManager struct {
ConfigPath string
Config Config
StateConfig StateConfig
}
type Differ ¶
type Differ struct {
StateConfig StateConfig
// contains filtered or unexported fields
}
type StateConfig ¶
type StateConfig struct {
Context string `yaml:"context"`
ContextName string `yaml:"contextName"`
ContextAbsPath string `yaml:"contextAbsPath"`
Target string `yaml:"target"`
Linked map[string][]string `yaml:"linked"`
}
func ReadStatefile ¶
func ReadStatefile() (stateConfig StateConfig, err error)
func (*StateConfig) MarshalYAML ¶
func (l *StateConfig) MarshalYAML() (int interface{}, err error)
func (*StateConfig) UnmarshalYAML ¶
func (l *StateConfig) UnmarshalYAML(unmarshal func(interface{}) error) error
type UsageHelper ¶
func (*UsageHelper) AddArg ¶
func (helper *UsageHelper) AddArg(name string, description string)
func (*UsageHelper) AddOptArg ¶
func (helper *UsageHelper) AddOptArg(name string, description string)
func (*UsageHelper) Parse ¶
func (helper *UsageHelper) Parse() error
Click to show internal directories.
Click to hide internal directories.