diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2018-08-27 18:55:56 +1000 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2018-08-27 19:20:07 +1000 |
commit | 43f612feb128ba34a8192db78e4623ebc7af405a (patch) | |
tree | b1bb6fef6b440d8d4984d914c5373ed356bcf65c /pkg/config | |
parent | 12261ceb05c4dd26d7e53a96f835e7886092b88a (diff) | |
parent | e72d090c5c9e426d11bbcf74f3cf3a32de21d3f5 (diff) |
Merge branch 'master' into feature/auto-updates
Diffstat (limited to 'pkg/config')
-rw-r--r-- | pkg/config/app_config.go | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/pkg/config/app_config.go b/pkg/config/app_config.go index 36cfdb9f4..fd3acb212 100644 --- a/pkg/config/app_config.go +++ b/pkg/config/app_config.go @@ -40,7 +40,7 @@ type AppConfigurer interface { // NewAppConfig makes a new app config func NewAppConfig(name, version, commit, date string, buildSource string, debuggingFlag *bool) (*AppConfig, error) { - defaultConfig := getDefaultConfig() + defaultConfig := GetDefaultConfig() userConfig, err := LoadConfig("config", defaultConfig) if err != nil { return nil, err @@ -205,26 +205,26 @@ func (c *AppConfig) LoadAppState() error { return yaml.Unmarshal(appStateBytes, c.AppState) } -func getDefaultConfig() []byte { - return []byte(` - gui: - ## stuff relating to the UI - scrollHeight: 2 - theme: - activeBorderColor: - - white - - bold - inactiveBorderColor: - - white - optionsTextColor: - - blue - git: - # stuff relating to git - os: - # stuff relating to the OS - update: - method: prompt # can be: prompt | background | never - days: 14 # how often a update is checked for +func GetDefaultConfig() []byte { + return []byte( + `gui: + ## stuff relating to the UI + scrollHeight: 2 + theme: + activeBorderColor: + - white + - bold + inactiveBorderColor: + - white + optionsTextColor: + - blue +git: + # stuff relating to git +os: + # stuff relating to the OS +update: + method: prompt # can be: prompt | background | never + days: 14 # how often a update is checked for `) } |