We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ae3688b commit c1e22e5Copy full SHA for c1e22e5
internal/config/paths.go
@@ -12,6 +12,10 @@ import (
12
const AppName = "gogcli"
13
14
func Dir() (string, error) {
15
+ if xdg := strings.TrimSpace(os.Getenv("XDG_CONFIG_HOME")); xdg != "" {
16
+ return filepath.Join(xdg, AppName), nil
17
+ }
18
+
19
base, err := os.UserConfigDir()
20
if err != nil {
21
return "", fmt.Errorf("resolve user config dir: %w", err)
0 commit comments