Skip to content

Commit

Permalink
Merge pull request #83 from essentialkaos/develop
Browse files Browse the repository at this point in the history
Version 3.2.2
  • Loading branch information
andyone authored Nov 4, 2024
2 parents 978b8c9 + c442b32 commit 6e96940
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 23 deletions.
11 changes: 7 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
################################################################################

# This Makefile generated by GoMakeGen 3.2.1 using next command:
# This Makefile generated by GoMakeGen 3.2.2 using next command:
# gomakegen --mod --strip .
#
# More info: https://kaos.sh/gomakegen
Expand Down Expand Up @@ -54,19 +54,22 @@ update: mod-update ## Update dependencies to the latest versions
vendor: mod-vendor ## Make vendored copy of dependencies

mod-init:
@echo "[1/2] Modules initialization…"
@echo "[1/3] Modules initialization…"
@rm -f go.mod go.sum
ifdef MODULE_PATH ## Module path for initialization (String)
@go mod init $(MODULE_PATH)
else
@go mod init
endif

@echo "[37m[2/2][0m [36;1mDependencies cleanup…[0m"
@echo "[37m[2/3][0m [36;1mDependencies cleanup…[0m"
ifdef COMPAT ## Compatible Go version (String)
@go mod tidy $(VERBOSE_FLAG) -compat=$(COMPAT) -go=$(COMPAT)
else
@go mod tidy $(VERBOSE_FLAG)
endif
@echo "[3/3] Stripping toolchain info…"
@grep -q 'toolchain ' go.mod && go mod edit -toolchain=none || :

mod-update:
@echo "[1/4] Updating dependencies…"
Expand Down Expand Up @@ -119,6 +122,6 @@ help: ## Show this info
| sort -h \
| awk 'BEGIN {FS = " .*?## "}; {printf " \033[32m%-11s\033[0m %s\n", $$1, $$2}'
@echo -e ''
@echo -e '\033[90mGenerated by GoMakeGen 3.2.1\033[0m\n'
@echo -e '\033[90mGenerated by GoMakeGen 3.2.2\033[0m\n'

################################################################################
13 changes: 8 additions & 5 deletions cli/cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ import (
// App info
const (
APP = "GoMakeGen"
VER = "3.2.1"
VER = "3.2.2"
DESC = "Utility for generating makefiles for Go applications"
)

Expand Down Expand Up @@ -143,7 +143,7 @@ func Init(gitRev string, gomod []byte) {

if !errs.IsEmpty() {
terminal.Error("Options parsing errors:")
terminal.Error(errs.String())
terminal.Error(errs.Error("- "))
os.Exit(1)
}

Expand Down Expand Up @@ -1096,18 +1096,21 @@ func (m *Makefile) getModTarget() string {
}

result := "mod-init:\n"
result += getActionText(1, 2, "Modules initialization…")
result += getActionText(1, 3, "Modules initialization…")
result += "\t@rm -f go.mod go.sum\n"
result += "ifdef MODULE_PATH ## Module path for initialization (String)\n"
result += "\t@go mod init $(MODULE_PATH)\n"
result += "else\n"
result += "\t@go mod init\n"
result += "endif\n\n"
result += getActionText(2, 2, "Dependencies cleanup…")
result += getActionText(2, 3, "Dependencies cleanup…")
result += "ifdef COMPAT ## Compatible Go version (String)\n"
result += "\t@go mod tidy $(VERBOSE_FLAG) -compat=$(COMPAT) -go=$(COMPAT)\n"
result += "else\n"
result += "\t@go mod tidy $(VERBOSE_FLAG)\n"
result += "endif\n\n"
result += "endif\n"
result += getActionText(3, 3, "Stripping toolchain info…")
result += "\t@grep -q 'toolchain ' go.mod && go mod edit -toolchain=none || :\n\n"

result += "mod-update:\n"
result += getActionText(1, 4, "Updating dependencies…")
Expand Down
8 changes: 4 additions & 4 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
module github.com/essentialkaos/gomakegen/v3

go 1.22.7
go 1.22.8

require github.com/essentialkaos/ek/v13 v13.5.1
require github.com/essentialkaos/ek/v13 v13.10.0

require (
github.com/essentialkaos/depsy v1.3.0 // indirect
golang.org/x/sys v0.25.0 // indirect
github.com/essentialkaos/depsy v1.3.1 // indirect
golang.org/x/sys v0.26.0 // indirect
)
20 changes: 10 additions & 10 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
github.com/essentialkaos/check v1.4.0 h1:kWdFxu9odCxUqo1NNFNJmguGrDHgwi3A8daXX1nkuKk=
github.com/essentialkaos/check v1.4.0/go.mod h1:LMKPZ2H+9PXe7Y2gEoKyVAwUqXVgx7KtgibfsHJPus0=
github.com/essentialkaos/depsy v1.3.0 h1:CN7bRgBU2jGTHSkg/Sh38eDUn7cvmaTp2sxFt2HpFeU=
github.com/essentialkaos/depsy v1.3.0/go.mod h1:kpiTAV17dyByVnrbNaMcZt2jRwvuXClUYOzpyJQwtG8=
github.com/essentialkaos/ek/v13 v13.5.1 h1:xkr3d5uAzs69AqI0oKHjjZIsowKdR117AMBv+Dop4Fk=
github.com/essentialkaos/ek/v13 v13.5.1/go.mod h1:KBOtJlrIC2etc/EXvMdbz1JeKmtkuVdK6uRW/ap0OPM=
github.com/essentialkaos/check v1.4.1 h1:SuxXzrbokPGTPWxGRnzy0hXvtb44mtVrdNxgPa1s4c8=
github.com/essentialkaos/check v1.4.1/go.mod h1:xQOYwFvnxfVZyt5Qvjoa1SxcRqu5VyP77pgALr3iu+M=
github.com/essentialkaos/depsy v1.3.1 h1:00k9QcMsdPM4IzDaEFHsTHBD/zoM0oxtB5+dMUwbQa8=
github.com/essentialkaos/depsy v1.3.1/go.mod h1:B5+7Jhv2a2RacOAxIKU2OeJp9QfZjwIpEEPI5X7auWM=
github.com/essentialkaos/ek/v13 v13.10.0 h1:uoLNjiDRJ/bOPAciq8Ff92r+XHgTm+rBI4ItOtZje9k=
github.com/essentialkaos/ek/v13 v13.10.0/go.mod h1:6G9EPJ/k4N0mugTLqPuWS/fb7K5JwoEqZSkNSfBCsgg=
github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE=
github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk=
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M=
github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA=
golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34=
golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR38lUII=
github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o=
golang.org/x/sys v0.26.0 h1:KHjCJyddX0LoSTb3J+vWpupP9p0oznkqVk/IfjymZbo=
golang.org/x/sys v0.26.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=

0 comments on commit 6e96940

Please sign in to comment.