Makefile: Run golangci-lint config verify

This more closely matches the behavior of the github action.

In the .golangci.yml config file move the exclude-dirs list under issues
where it belongs.
This commit is contained in:
Brian C. Lane 2025-02-19 08:52:04 -08:00 committed by Brian C. Lane
parent 0256e09031
commit 06bc5d4d59
2 changed files with 4 additions and 3 deletions

View file

@ -1,6 +1,3 @@
exclude-dirs:
- vendor
linters-settings: linters-settings:
govet: govet:
disable: disable:
@ -23,6 +20,9 @@ run:
timeout: 5m timeout: 5m
issues: issues:
exclude-dirs:
- vendor
# Maximum issues count per one linter. Set to 0 to disable. Default is 50. # Maximum issues count per one linter. Set to 0 to disable. Default is 50.
max-issues-per-linter: 0 max-issues-per-linter: 0

View file

@ -356,6 +356,7 @@ SHELLCHECK_FILES=$(shell find . -name "*.sh" -not -regex "./vendor/.*")
.PHONY: lint .PHONY: lint
lint: $(GOLANGCI_LINT_CACHE_DIR) container_composer_golangci_built.info lint: $(GOLANGCI_LINT_CACHE_DIR) container_composer_golangci_built.info
./tools/prepare-source.sh ./tools/prepare-source.sh
podman run -t --rm -v $(SRCDIR):/app:z -v $(GOLANGCI_LINT_CACHE_DIR):/root/.cache:z -w /app $(GOLANGCI_COMPOSER_IMAGE) golangci-lint config verify -v
podman run -t --rm -v $(SRCDIR):/app:z -v $(GOLANGCI_LINT_CACHE_DIR):/root/.cache:z -w /app $(GOLANGCI_COMPOSER_IMAGE) golangci-lint run -v podman run -t --rm -v $(SRCDIR):/app:z -v $(GOLANGCI_LINT_CACHE_DIR):/root/.cache:z -w /app $(GOLANGCI_COMPOSER_IMAGE) golangci-lint run -v
echo "$(SHELLCHECK_FILES)" | xargs shellcheck --shell bash -e SC1091 -e SC2002 -e SC2317 echo "$(SHELLCHECK_FILES)" | xargs shellcheck --shell bash -e SC1091 -e SC2002 -e SC2317