mirror of
https://github.com/open-telemetry/opentelemetry-go.git
synced 2024-11-28 08:38:51 +02:00
run go build on all modules to catch compilation errors (#250)
golangci-lint just issues an unreadable warning and quits with a successful exit status on compilation error. just run a round of go build ./... to catch those as hard errors.
This commit is contained in:
parent
f420f7409d
commit
cdf3f492d1
4
Makefile
4
Makefile
@ -32,6 +32,10 @@ $(TOOLS_DIR)/stringer: go.mod go.sum tools.go
|
||||
precommit: $(TOOLS_DIR)/golangci-lint $(TOOLS_DIR)/misspell $(TOOLS_DIR)/stringer
|
||||
PATH="$(abspath $(TOOLS_DIR)):$${PATH}" go generate ./...
|
||||
# TODO: Fix this on windows.
|
||||
set -e; for dir in $(ALL_GO_MOD_DIRS); do \
|
||||
echo "compiling all packages in $${dir}"; \
|
||||
(cd "$${dir}" && go build ./...); \
|
||||
done
|
||||
set -e; for dir in $(ALL_GO_MOD_DIRS); do \
|
||||
echo "golangci-lint in $${dir}"; \
|
||||
(cd "$${dir}" && $(abspath $(TOOLS_DIR))/golangci-lint run --fix); \
|
||||
|
Loading…
Reference in New Issue
Block a user