-
Notifications
You must be signed in to change notification settings - Fork 18k
cmd/go: gofmt should ignore vendor #33962
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
Labels
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
WaitingForInfo
Issue is not actionable because of missing required information, which needs to be provided.
Comments
/cc @bcmills @jayconrod |
@abhigenie92, please fill out the full issue template — specifically, it would be helpful to know the exact commands you ran that led to confusion, and to clarify what you observed vs. what you expected. Specifically:
|
See also #29751. |
Timed out in state WaitingForInfo. Closing. (I am just a bot, though. Please speak up if this is a mistake or you have the requested information.) |
atc0005
added a commit
to atc0005/check-mail
that referenced
this issue
Apr 27, 2020
- Vendor dependencies - Update Makefile and helper shell scripts - include `-mod=vendor` build flag for applicable `go` commands to reflect Go 1.13 vendoring - this includes specifying `-mod=vendor` even for `go list` commands, which unless specified results in dependencies being downloaded, even when they're already provided in a local, top-level `vendor` directory - update `gofmt` linting call to use a workaround that explictly excludes the `/vendor/` path golang/go#33962 (comment) - Update GitHub Actions Workflows - Disable running `go get` after checking out code - Exclude `vendor` folder from ... - Markdown linting checks - tests - basic build refs #24
atc0005
added a commit
to atc0005/check-mail
that referenced
this issue
Apr 27, 2020
- Vendor dependencies - Update Makefile and helper shell scripts - include `-mod=vendor` build flag for applicable `go` commands to reflect Go 1.13 vendoring - this includes specifying `-mod=vendor` even for `go list` commands, which unless specified results in dependencies being downloaded, even when they're already provided in a local, top-level `vendor` directory - update `gofmt` linting call to use a workaround that explictly excludes the `/vendor/` path golang/go#33962 (comment) - Update GitHub Actions Workflows - Disable running `go get` after checking out code - Exclude `vendor` folder from ... - Markdown linting checks - tests - basic build refs #24
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
WaitingForInfo
Issue is not actionable because of missing required information, which needs to be provided.
When you run
go fmt $$(go list ./...)
it ignores vendor by default butgofmt .
doesn't do that.The use case is if you run fmt without the code modification in-place and ignore the vendor.
One way is
gofmt -l (find . -type f -name '*.go'| grep -v "/vendor/")
, is there an easier way?The text was updated successfully, but these errors were encountered: