From be27fb94b49117a635839e09da32c75880cb484b Mon Sep 17 00:00:00 2001 From: Dar-rius Date: Wed, 2 Nov 2022 19:47:24 +0000 Subject: [PATCH] change path for path.json --- cmd/add.go | 2 +- cmd/ls.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/add.go b/cmd/add.go index 1994881..81f1622 100644 --- a/cmd/add.go +++ b/cmd/add.go @@ -53,7 +53,7 @@ func addProjectActually(project *Project) { func addProject(project *Project) { //the environment variable is stored in a variable in order to create and find the path.json file in the directory where the app is located filEnv := os.Getenv("goproject") - _, errr := os.OpenFile(filEnv+"\\path.json", os.O_APPEND|os.O_WRONLY|os.O_CREATE, 0600) + _, errr := os.OpenFile(filEnv+"/path.json", os.O_APPEND|os.O_WRONLY|os.O_CREATE, 0600) if errr != nil { panic(errr) } diff --git a/cmd/ls.go b/cmd/ls.go index c693960..ffd332d 100644 --- a/cmd/ls.go +++ b/cmd/ls.go @@ -17,7 +17,7 @@ var lsCmd = &cobra.Command{ Run: func(cmd *cobra.Command, args []string) { //the environment variable is stored in a variable in order to create and find the path.json file in the directory where the app is located filEnv := os.Getenv("goproject") - file, err := os.ReadFile(filEnv + "\\path.json") + file, err := os.ReadFile(filEnv + "/path.json") if err != nil { panic(err) }