diff --git a/cmd/config.go b/cmd/config.go index 1dc5312..c77a26e 100644 --- a/cmd/config.go +++ b/cmd/config.go @@ -11,6 +11,7 @@ import ( ) const lumercFile string = ".lumerc" +const lumeConfigFile string = "lume.conf" type Config struct { AccessToken string `toml:"access_token"` @@ -122,6 +123,15 @@ func getConfigPath() string { } } + // ~/.config/lume/lume.conf + homeDir, err = os.UserHomeDir() + if err == nil { + tryPath = path.Join(homeDir, ".config/lume", lumeConfigFile) + if _, err := os.Stat(tryPath); !os.IsNotExist(err) { + configPath = tryPath + } + } + // ./.lumerc cwd, err = os.Getwd() if err == nil {