diff options
author | matthieu <matthieu.cneude@gmail.com> | 2021-10-26 06:39:27 +0200 |
---|---|---|
committer | matthieu <matthieu.cneude@gmail.com> | 2021-10-26 06:39:27 +0200 |
commit | d8b871c391d5eb8b979cef8dda6919add980ba71 (patch) | |
tree | c95702f191939f67796fbc0cb666666876b1c157 | |
parent | f4b0b4aa696a7c8d29c62007120f9c015c4ad3d0 (diff) | |
parent | 2c426814b8294cc004814d8da0754b04ca24e22b (diff) |
Merge branch 'master' of github.com:Phantas0s/devdash
-rw-r--r-- | cmd/config.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/cmd/config.go b/cmd/config.go index a0cbe90..fa814d3 100644 --- a/cmd/config.go +++ b/cmd/config.go @@ -175,7 +175,7 @@ func dashPath() string { func mapConfig(cfgFile string) (config, string) { if cfgFile == "" { cfgFile = "default.yml" - createConfig(dashPath(), cfgFile, defaultConfig()) + createConfig(dashPath(), cfgFile, defaultConfig(dashPath())) } // viper.AddConfigPath(home) @@ -283,8 +283,8 @@ func (c config) KEdit() string { return kEdit } -func defaultConfig() string { - return `--- +func defaultConfig(dashPath string) string { + return fmt.Sprintf(`--- general: refresh: 600 keys: @@ -293,7 +293,7 @@ general: projects: - - name: Default dashboard located at $HOME/.config/devdash/default.yml + - name: Default dashboard located at %s services: monitor: address: "https://thevaluable.dev" @@ -305,5 +305,5 @@ projects: - name: mon.box_availability options: title: " thevaluable.dev status " - color: yellow` + color: yellow`, filepath.Join(dashPath, "default.yml")) } |