-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
28 lines (21 loc) · 909 Bytes
/
Copy pathMakefile
File metadata and controls
28 lines (21 loc) · 909 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# A Self-Documenting Makefile: http://marmelab.com/blog/2016/02/29/auto-documented-makefile.html
.PHONY: setup
setup: ## Install dev dependencies
go install github.com/client9/misspell/cmd/misspell@latest
npm install
.PHONY: misspell
misspell: ## Run misspell checks
misspell -i cancelled -locale US -source text -error ipa
.PHONY: fix-lint
fix-lint: ## Fix lint
misspell -i cancelled -locale US -source text -w ipa
npx prettier . --write
.PHONY: check
check: misspell ## Run all checks
.PHONY: list
list: ## List all make targets
@${MAKE} -pRrn : -f $(MAKEFILE_LIST) 2>/dev/null | awk -v RS= -F: '/^# File/,/^# Finished Make data base/ {if ($$1 !~ "^[#.]") {print $$1}}' | egrep -v -e '^[^[:alnum:]]' -e '^$@$$' | sort
.PHONY: help
.DEFAULT_GOAL := help
help:
@grep -h -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'