Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,5 @@ services:
script:
- ./build.sh
- make test
- make staticcheck
- ./artifact.sh
8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ TOOLS_BIN = tools/bin
NPM_BIN = node_modules/.bin

OAPI_CODEGEN = $(TOOLS_BIN)/oapi-codegen
STATICCHECK = $(TOOLS_BIN)/staticcheck
SWAGGER_CLI = $(NPM_BIN)/swagger-cli

NPM_PKG_SPECS = \
Expand Down Expand Up @@ -34,6 +35,9 @@ generate: $(SWAGGER_CLI) $(OAPI_CODEGEN)
test:
GOWORK=off ./test.sh

$(STATICCHECK):
GOBIN=$(shell pwd)/$(TOOLS_BIN) go install honnef.co/go/tools/cmd/staticcheck@2023.1.6

$(OAPI_CODEGEN):
GOBIN=$(shell pwd)/$(TOOLS_BIN) go install github.com/deepmap/oapi-codegen/cmd/oapi-codegen@v1.13.4

Expand All @@ -46,3 +50,7 @@ npm-tools:
# has to install all the packages all at the same time. But it saves us from
# having to muck with packages.json.
npm i --no-save --local $(NPM_PKG_SPECS)

.PHONY: staticcheck
staticcheck: $(STATICCHECK)
GOWORK=off $(TOOLS_BIN)/staticcheck --fail none ./...