handle user variables on all platforms

This commit is contained in:
Gokcehan committed 2017-08-06 11:05:46 +03:00
1 parent ae4a29e550
commit cb577a4c3a
7 files changed
+80 -49

No files matched your search

+1 -1
View File
@@ -164,7 +164,7 @@ func matchExec(s string) (matches []string, longest string) {
}
func matchFile(s string) (matches []string, longest string) {
dir := strings.Replace(s, "~", envHome, -1)
dir := strings.Replace(s, "~", gUser.HomeDir, -1)
if !filepath.IsAbs(dir) {
wd, err := os.Getwd()