Skip to content

Commit

Permalink
* fix
Browse files Browse the repository at this point in the history
  • Loading branch information
JGottschick committed Sep 20, 2024
1 parent ef0a585 commit 823e25e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion core/version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.3.0
0.3.2
4 changes: 2 additions & 2 deletions templates/core/config.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ var (
)

func init() {
AppConfig.Service = stringy.New("{{.ModuleName}}").SnakeCase("?", "").ToUpper()
AppConfig.Service = service
AppConfig.Host, _ = os.Hostname()
AppConfig.User = os.Getenv("USER")
sid, _ := uuid.NewUUID()
Expand All @@ -63,7 +63,7 @@ func init() {
flag.BoolVar(&AppConfig.Version, "V", AppConfig.Version, "print version")

if AppConfig.Name == "" {
AppConfig.Name = AppConfig.Service
AppConfig.Name = service
}
if AppConfig.Title == "" {
AppConfig.Title = AppConfig.Name
Expand Down
4 changes: 3 additions & 1 deletion templates/core/info.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ import (
"strings"
)

const service = "{{.ModuleName}}"

type Info struct {
Service string
Name string
Expand All @@ -22,5 +24,5 @@ var (
)

func init() {
AppInfo = Info{Service: "{{.ModuleName}}", Version: Version, Name: ""}
AppInfo = Info{Service: service, Version: Version, Name: ""}
}

0 comments on commit 823e25e

Please sign in to comment.