Skip to content

Commit a29d1ab

Browse files
authored
Merge pull request #16 from classmethod/fix/file-path-separator-difference
2 parents 14ecb5f + 7835106 commit a29d1ab

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

utils/utils.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package utils
22

33
import (
4+
"path/filepath"
45
"strings"
56

67
"github.com/mitchellh/go-homedir"
@@ -17,5 +18,8 @@ func ExpandPath(path string) string {
1718
path = strings.Replace(path, "~/", dir, 1)
1819
}
1920
// log.Printf("path = %s", path)
21+
22+
// for file path separator difference between windows and unix
23+
path = filepath.FromSlash(path)
2024
return path
2125
}

0 commit comments

Comments
 (0)