2021-03-30 19:59:26 +02:00
|
|
|
.PHONY: build
|
|
|
|
build:
|
|
|
|
goreleaser build --rm-dist --snapshot
|
|
|
|
|
|
|
|
.PHONY: release
|
|
|
|
release:
|
|
|
|
goreleaser release --rm-dist --snapshot --skip-publish
|
|
|
|
|
|
|
|
.PHONY: generate
|
|
|
|
generate:
|
|
|
|
go generate
|
|
|
|
|
|
|
|
.PHONY: lint
|
2021-08-23 10:51:17 +02:00
|
|
|
lint: lint-go lint-buf lint-js
|
|
|
|
|
|
|
|
.PHONY: lint-go
|
|
|
|
lint-go:
|
2021-08-26 11:48:26 +02:00
|
|
|
golangci-lint run --timeout 10m --enable-all --disable=exhaustivestruct,godox
|
2021-08-23 10:51:17 +02:00
|
|
|
|
|
|
|
.PHONY: lint-buf
|
|
|
|
lint-buf:
|
2021-05-05 11:14:17 +02:00
|
|
|
buf lint -v
|
2021-03-30 19:59:26 +02:00
|
|
|
|
2021-08-23 10:51:17 +02:00
|
|
|
.PHONY: lint-js
|
|
|
|
lint-js:
|
|
|
|
eslint assets/web/files/**.js
|
|
|
|
|
2021-03-30 19:59:26 +02:00
|
|
|
.PHONY: test
|
|
|
|
test:
|
|
|
|
go test -v -race -cover ./...
|
|
|
|
|
2021-04-10 17:47:18 +02:00
|
|
|
.PHONY: test-integration
|
2021-06-01 15:18:39 +02:00
|
|
|
test-integration: build
|
|
|
|
go test -v -tags=integration -timeout=240m
|
2021-04-10 17:47:18 +02:00
|
|
|
|
2021-06-01 14:25:37 +02:00
|
|
|
.PHONY: test-all
|
|
|
|
test-all: test test-integration
|
|
|
|
|
2021-03-30 19:59:26 +02:00
|
|
|
.PHONY: readme
|
|
|
|
readme:
|
|
|
|
goreadme -title revive > README.md
|
2021-04-10 17:47:18 +02:00
|
|
|
|
|
|
|
.PHONY: tidy
|
|
|
|
tidy:
|
|
|
|
go mod tidy
|
|
|
|
go mod vendor
|
|
|
|
|
|
|
|
.PHONY: build-image
|
|
|
|
build-image:
|
2021-06-01 15:18:39 +02:00
|
|
|
./scripts/build.sh
|
2021-05-04 08:41:43 +02:00
|
|
|
|
|
|
|
.PHONY: install-tools
|
|
|
|
install-tools:
|
2021-08-20 13:32:09 +02:00
|
|
|
@cat tools.go | grep _ | awk -F'"' '{print $$2}' | xargs -tI % go install %
|
2021-05-05 11:14:17 +02:00
|
|
|
|
|
|
|
.PHONY: grpc-gen
|
|
|
|
grpc-gen:
|
|
|
|
buf generate -v
|
2021-08-20 13:32:09 +02:00
|
|
|
|
|
|
|
.PHONY: air
|
|
|
|
air:
|
|
|
|
air
|
2021-08-23 12:55:18 +02:00
|
|
|
|
|
|
|
.PHONY: drone-local
|
|
|
|
drone-local:
|
|
|
|
drone exec --trusted --timeout 5h
|
|
|
|
|
|
|
|
.PHONY: clean
|
|
|
|
clean:
|
|
|
|
rm -rf node_modules
|
|
|
|
rm -rf package* || exit 0
|