config

package
v0.0.0-...-8dd6030 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2017 License: MIT Imports: 11 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 {
	OutFormat       string                `mapstructure:"out-format"`
	FieldsSeparator string                `mapstructure:"fields-separator"`
	HumanReadable   bool                  `mapstructure:"human-readable"`
	AdjustWidth     bool                  `mapstructure:"adjust-width"`
	Interval        time.Duration         `mapstructure:"interval"`
	Keydir          string                `mapstructure:"ssh-key-dir"`
	FieldsOut       []string              `mapstructure:"fields-out"`
	ChangeFactor    float32               `mapstructure:"change-factor"`
	Hosts           map[string]HostConfig `mapstructure:"hosts"`
	Server          string                `mapstructure:"server"`
	Debug           bool
	// contains filtered or unexported fields
}

func GetConfig

func GetConfig() Config

func (*Config) HasFieldOut

func (c *Config) HasFieldOut(name string) bool

type HostConfig

type HostConfig struct {
	User    string `mapstructure:"user"`
	Addr    string `mapstructure:"addr"`
	Keypath string `mapstructure:"keypath"`
	Command string `mapstructure:"cmd"`
}

func (*HostConfig) ExpandKeypath

func (h *HostConfig) ExpandKeypath(keydir string)

func (HostConfig) NormAddr

func (h HostConfig) NormAddr() string

Jump to

Keyboard shortcuts

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