@@ -29,17 +29,19 @@ endif
2929default : build
3030
3131bin/golangci-lint :
32+ @echo " ==> Installing golangci-lint..."
3233 mkdir -p $(BIN )
3334 GOBIN=$(BIN ) go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@v2.10.1
3435
3536tools_go_files = $(shell find tools \( -name '* .go' -or -name '* .mod' -or -name '* .sum' \) -and -not -name '*_test.go' -maxdepth 4)
3637bin/custom-gcl : bin/golangci-lint $(tools_go_files )
37- $(BIN ) /golangci-lint custom --name custom-gcl --destination $(BIN )
38+ @echo " ==> Building custom-gcl..."
39+ @$(BIN ) /golangci-lint custom --name custom-gcl --destination $(BIN )
3840
3941tools : bin/custom-gcl go.sum
4042
4143go.sum : go.mod $(shell find github -name '* .go')
42- go mod tidy
44+ @ go mod tidy
4345
4446build : lintcheck
4547 CGO_ENABLED=0 go build -ldflags=" -s -w" ./...
@@ -58,16 +60,16 @@ lintcheck: tools
5860 $(BIN ) /custom-gcl run ./...
5961
6062.golangci.new.yml : .golangci.yml .golangci.strict.yml
61- yq eval-all ' select(fileIndex == 0) *+ select(fileIndex == 1)' .golangci.yml .golangci.strict.yml > .golangci.new.yml
63+ @ yq eval-all ' select(fileIndex == 0) *+ select(fileIndex == 1)' .golangci.yml .golangci.strict.yml > .golangci.new.yml
6264
6365lintcheck-new : tools .golangci.new.yml
6466 @branch=$$(git rev-parse --abbrev-ref HEAD ) ; \
65- printf " ==> Checking source code against linters on branch: \033[1m%s\033[0m...\n" " 🌿 $$ branch 🌿"
67+ printf " ==> Checking changed source code against linters on branch: \033[1m%s\033[0m...\n" " 🌿 $$ branch 🌿"
6668 $(BIN ) /custom-gcl run ./... --new-from-merge-base main --config .golangci.new.yml
6769
6870lintcheck-strict : tools .golangci.new.yml
6971 @branch=$$(git rev-parse --abbrev-ref HEAD ) ; \
70- printf " ==> Checking source code against linters on branch: \033[1m%s\033[0m...\n" " 🌿 $$ branch 🌿"
72+ printf " ==> Checking source code against strict linters on branch: \033[1m%s\033[0m...\n" " 🌿 $$ branch 🌿"
7173 $(BIN ) /custom-gcl run ./... --config .golangci.new.yml
7274
7375test :
0 commit comments