-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Run GCI as make fix-imports #17956
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Run GCI as make fix-imports #17956
Changes from all commits
1077c27
8d7b778
c812924
ff89aee
53e545e
5961e9b
755aaa9
446e39a
e40198c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -702,13 +702,16 @@ lint-go: | |
| golangci-lint run -c .golangci.yml --build-tags='$(LIBFIDO2_TEST_TAG) $(TOUCHID_TAG) $(PIV_TEST_TAG)' $(GO_LINT_FLAGS) | ||
|
|
||
| .PHONY: fix-imports | ||
| fix-imports: GOLANG_LINT_ARGS = --build-tags='$(LIBFIDO2_TEST_TAG) $(TOUCHID_TAG) $(PIV_TEST_TAG)' --fix | ||
| fix-imports: | ||
| golangci-lint run -c .golangci.yml $(GOLANG_LINT_ARGS) | ||
| cd api/ && golangci-lint run -c ../.golangci.yml $(GOLANG_LINT_ARGS) | ||
| cd build.assets/tooling && golangci-lint run -c ../../.golangci.yml $(GOLANG_LINT_ARGS) | ||
| cd .cloudbuild/scripts && golangci-lint run -c ../../.golangci.yml $(GOLANG_LINT_ARGS) | ||
| cd assets/backport && golangci-lint run -c ../../.golangci.yml $(GOLANG_LINT_ARGS) | ||
| make -C build.assets/ fix-imports | ||
|
|
||
| .PHONY: fix-imports/host | ||
| fix-imports/host: | ||
| @if ! type gci >/dev/null 2>&1; then\ | ||
| echo 'gci is not installed or is missing from PATH, consider installing it ("go install github.com/daixiang0/gci@latest") or use "make -C build.assets/ fix-imports"';\ | ||
| exit 1;\ | ||
| fi | ||
| gci write -s 'standard,default,prefix(github.com/gravitational/teleport)' --skip-generated . | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nice, I didn't realize
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
|
|
||
| .PHONY: lint-build-tooling | ||
| lint-build-tooling: GO_LINT_FLAGS ?= | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.