Skip to content

Commit

Permalink
Pin goimports, skip gen dir
Browse files Browse the repository at this point in the history
Signed-off-by: Andrew Dye <[email protected]>
  • Loading branch information
andrewwdye committed May 21, 2024
1 parent f4391aa commit 3bf3a72
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion boilerplate/flyte/golang_test_targets/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ lint: download_tooling #lints the package for common code smells
# If code is failing goimports linter, this will fix.
# skips 'vendor'
.PHONY: goimports
goimports:
goimports: download_tooling
@${REPO_ROOT}/boilerplate/flyte/golang_test_targets/goimports

.PHONY: mod_download
Expand Down
1 change: 1 addition & 0 deletions boilerplate/flyte/golang_test_targets/download_tooling.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ tools=(
"github.com/daixiang0/gci"
"github.com/alvaroloes/enumer"
"github.com/pseudomuto/protoc-gen-doc/cmd/protoc-gen-doc"
"golang.org/x/tools/cmd/[email protected]"
)

# This ensures pflags are up to date.
Expand Down
2 changes: 1 addition & 1 deletion boilerplate/flyte/golang_test_targets/goimports
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
#
# TO OPT OUT OF UPDATES, SEE https://github.com/flyteorg/boilerplate/blob/master/Readme.rst

goimports -w $(find . -type f -name '*.go' -not -path "./vendor/*" -not -path "./pkg/client/*" -not -path "./boilerplate/*")
goimports -w $(find . -type f -name '*.go' -not -path "./vendor/*" -not -path "./pkg/client/*" -not -path "./boilerplate/*" -not -path "./gen/*")
GL_DEBUG=linters_output,env golangci-lint run --timeout=5m --exclude deprecated -v --fix

0 comments on commit 3bf3a72

Please sign in to comment.