This repository has been archived by the owner on Dec 10, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 961
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
57a8f8f
commit 0886867
Showing
5 changed files
with
47 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,22 @@ | ||
setup: | ||
go mod tidy | ||
@go install mvdan.cc/gofumpt@latest | ||
@go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest | ||
.PHONY: setup | ||
##@ General | ||
|
||
.PHONY: help | ||
help: ## Display this help | ||
@awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m<target>\033[0m\n"} /^[a-zA-Z_0-9-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST) | ||
|
||
test: | ||
go test ./... -race #-v?? | ||
.PHONY: test | ||
##@ Development | ||
|
||
fmt: | ||
fmt: ## Format code | ||
@gofumpt -l -w . | ||
.PHONY: fmt | ||
|
||
lint: | ||
@golangci-lint run --config .golangci.yml | ||
.PHONY: lint | ||
lint: ## Run linter | ||
@golangci-lint run | ||
|
||
setup: ## Setup your local environment | ||
go mod tidy | ||
@go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest | ||
@go install mvdan.cc/gofumpt@latest | ||
.PHONY: setup | ||
|
||
test: ## Run tests | ||
go test ./... -race |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters