Add quote string

This commit is contained in:
Joe Lim committed 2023-06-18 16:09:42 +10:00
1 parent a89dd4448c
commit 03f1c3b44c
3 files changed
+9 -1

No files matched your search

+1 -1
View File
@@ -85,7 +85,7 @@ func exportEnvVars() {
log.Printf("getting path to lf binary: %s", err) log.Printf("getting path to lf binary: %s", err)
lfPath = "lf" lfPath = "lf"
} }
os.Setenv("lf", lfPath) os.Setenv("lf", quoteString(lfPath))
} }
// used by exportOpts below // used by exportOpts below
+4
View File
@@ -232,3 +232,7 @@ func exportFiles(f string, fs []string, pwd string) {
os.Setenv("fx", envFiles) os.Setenv("fx", envFiles)
} }
} }
func quoteString(s string) string {
return s
}
+4
View File
@@ -195,3 +195,7 @@ func exportFiles(f string, fs []string, pwd string) {
os.Setenv("fx", envFiles) os.Setenv("fx", envFiles)
} }
} }
func quoteString(s string) string {
return fmt.Sprintf(`"%s"`, s)
}