Skip to content

Commit

Permalink
makefile: fix go-format target
Browse files Browse the repository at this point in the history
We added a few new modules with their own vendor directories, but the go-format target was outdated such that it wasn't igoring them. Fix this by simply updating it to ignore all `vendor/*` directories regardless of their parent path.

Signed-off-by: William Findlay <will@isovalent.com>
  • Loading branch information
willfindlay committed Feb 16, 2024
1 parent faee66d commit ff69e2b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ endif

.PHONY: go-format
go-format:
find . -name '*.go' -not -path './vendor/*' -not -path './api/vendor/*' -not -path './pkg/k8s/vendor/*' -not -path './api/v1/tetragon/codegen/*' | xargs gofmt -w
find . -name '*.go' -not -path '**/vendor/*' -not -path './pkg/k8s/vendor/*' -not -path './api/v1/tetragon/*' | xargs goimports -w

.PHONY: format
format: go-format clang-format
Expand Down

0 comments on commit ff69e2b

Please sign in to comment.