2022-01-14 13:51:56 +01:00
|
|
|
GO := go
|
2022-01-28 13:00:25 +01:00
|
|
|
|
2022-01-20 13:10:44 +01:00
|
|
|
GORELEASER := $(GO) run github.com/goreleaser/goreleaser@v1.3.1
|
2022-01-28 13:00:25 +01:00
|
|
|
GOLANGCI_LINT := $(GO) run github.com/golangci/golangci-lint/cmd/golangci-lint@v1.44.0
|
2020-10-13 15:26:40 +02:00
|
|
|
|
2022-01-14 13:51:56 +01:00
|
|
|
.PHONY: test
|
2020-10-13 15:26:40 +02:00
|
|
|
test:
|
2022-01-17 11:26:34 +01:00
|
|
|
$(GO) test -count=1 -v ./...
|
2020-10-13 15:26:40 +02:00
|
|
|
|
2022-01-14 13:51:56 +01:00
|
|
|
.PHONY: lint
|
2020-10-13 15:26:40 +02:00
|
|
|
lint:
|
2022-01-17 11:26:34 +01:00
|
|
|
$(GOLANGCI_LINT) run \
|
|
|
|
--enable-all \
|
|
|
|
--disable=godox,varnamelen \
|
|
|
|
--timeout 10m
|
2022-01-14 13:51:56 +01:00
|
|
|
|
|
|
|
.PHONY: tidy
|
|
|
|
tidy:
|
|
|
|
$(GO) mod tidy
|
|
|
|
$(GO) mod vendor
|
|
|
|
|
|
|
|
.PHONY: build
|
|
|
|
build:
|
|
|
|
$(GORELEASER) build --rm-dist --snapshot
|
|
|
|
|
|
|
|
.PHONY: release
|
|
|
|
release:
|
2022-01-20 13:10:44 +01:00
|
|
|
$(GORELEASER) release --rm-dist
|
|
|
|
|
|
|
|
.PHONY: release-snapshot
|
|
|
|
release-snapshot:
|
2022-01-14 13:51:56 +01:00
|
|
|
$(GORELEASER) release --rm-dist --snapshot --skip-publish
|