mirror of
https://github.com/gomods/athens
synced 2026-02-03 11:00:32 +00:00
* Set GO111MODULE to auto in golint script– #1743 As mentioned in #1743 the Go modules environment flag is set to `off` in the script which appears to cause a warning message for each module of the codebase that it is "not in GOROOT". Set to `auto` as this allows the same build to be run the original way should someone choose to delete the `go.mod` file from the project root. * Remove redundant code – golint script Go 1.17 ignores `GO111MODULE` and there are no directories in the project root called `mock`. * Replace `golint` with `go vet` `golint` is deprecated (and frozen) replace with the current `go vet`. This reported one issue on `main` branch: ```pkg/stash/with_etcd.go:33:28: loop variable ep captured by func literal``` Fixed loop variable capture with extraction to parameterised anonymous function passed loop variable and passed in to `errgroup.Go` call.
8 lines
116 B
Bash
Executable File
8 lines
116 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# check_golint.sh
|
|
# Run the linter on everything except generated code
|
|
set -euo pipefail
|
|
|
|
go vet ./...
|