Skip to content

Commit 4050202

Browse files
committed
change app name gproject -> goproject
1 parent f7971e2 commit 4050202

File tree

5 files changed

+5
-6
lines changed

5 files changed

+5
-6
lines changed

cmd/add.go

+1-2
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,12 @@ func addProjectActually(project *Project) {
5252
//the add Project function allows you to search the json file and save the data concerning the project (name and path)
5353
func addProject(project *Project) {
5454
//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
55-
filEnv := os.Getenv("gproject")
55+
filEnv := os.Getenv("goproject")
5656
_, errr := os.Open(filEnv + "/path.json")
5757
if errr != nil {
5858
_, errs := os.Create(filEnv + "/path.json")
5959
if errs != nil {
6060
panic(errs)
61-
os.Exit(0)
6261
}
6362
}
6463

cmd/go.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ var goCmd = &cobra.Command{
2929
// file and change directory by executing a shell command
3030
func goPath(project *string) {
3131
//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
32-
filEnv := os.Getenv("gproject")
32+
filEnv := os.Getenv("goproject")
3333
viper.SetConfigName("path")
3434
viper.SetConfigType("json")
3535
viper.AddConfigPath(filEnv)

cmd/ls.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ var lsCmd = &cobra.Command{
1616
example: gproject ls`,
1717
Run: func(cmd *cobra.Command, args []string) {
1818
//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
19-
filEnv := os.Getenv("gproject")
19+
filEnv := os.Getenv("goproject")
2020
file, err := os.ReadFile(filEnv + "/path.json")
2121
if err != nil {
2222
panic(err)

go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
module gproject
1+
module github.com/Dar_rius/goproject
22

33
go 1.18
44

main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Copyright © 2022 NAME HERE <EMAIL ADDRESS>
33
*/
44
package main
55

6-
import "gproject/cmd"
6+
import "github.com/Dar_rius/goproject/cmd"
77

88
func main() {
99
cmd.Execute()

0 commit comments

Comments
 (0)