There was an error while loading. Please reload this page.
2 parents 8c5bc75 + 9b7526c commit ad28233Copy full SHA for ad28233
1 file changed
config.go
@@ -22,11 +22,10 @@ var (
22
23
func homeDir() (string, error) {
24
dir := ""
25
-
26
- // *nix and MSYS Windows
27
- if dir = os.Getenv("HOME"); dir == "" {
28
- // Windows (if not running under MSYS)
+ if runtime.GOOS == "windows" {
29
dir = os.Getenv("USERPROFILE")
+ } else {
+ dir = os.Getenv("HOME")
30
}
31
if _, err := os.Stat(dir); err != nil {
32
return "", err
0 commit comments