summaryrefslogtreecommitdiff
path: root/path.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-10-28 21:59:48 -0500
committerJeff Carr <[email protected]>2025-10-28 21:59:48 -0500
commit200b76da8a0dd95b524d44e90a92106a9699d9fd (patch)
treefbd9110e1b464278c5b9faa93639fe887494effd /path.go
parent05d09b7584b4cd18676c68dd161142044437a7af (diff)
allow libraries to load a specific app env config fileHEADv0.0.13v0.0.12v0.0.11masterdevel
Diffstat (limited to 'path.go')
-rw-r--r--path.go9
1 files changed, 4 insertions, 5 deletions
diff --git a/path.go b/path.go
index 66a27fe..b9fffdb 100644
--- a/path.go
+++ b/path.go
@@ -1,25 +1,24 @@
package env
import (
+ "fmt"
"os"
"path/filepath"
"strings"
-
- "go.wit.com/log"
)
// adds a path to the ENV
func AddPath(newpath string) bool {
path := os.Getenv("PATH")
for _, p := range strings.Split(path, ":") {
- log.Info("Looking at path:", p)
+ fmt.Println("Looking at path:", p)
if p == newpath {
- log.Info("FOUND path:", p)
+ fmt.Println("FOUND path:", p)
return false
}
}
path = path + ":" + newpath
- log.Info("ADDING PATH:", path)
+ fmt.Println("ADDING PATH:", path)
os.Setenv("PATH", path)
return true
}