generated from devcontainers/feature-starter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
54 lines (38 loc) · 1.33 KB
/
Makefile
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#!/usr/bin/env -S make -f
MAKEFLAGS += --warn-undefined-variable
MAKEFLAGS += --no-builtin-rules
MAKEFLAGS += --silent
SHELL := bash
.ONESHELL:
.SHELLFLAGS := -eu -o pipefail -c
.DELETE_ON_ERROR:
.DEFAULT_GOAL := help
help: Makefile ## Show help
@grep -E '(^[a-zA-Z_-]+:.*?##.*$$)|(^##)' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[32m%-30s\033[0m %s\n", $$1, $$2}' | sed -e 's/\[32m##/[33m/'
# =============================================================================
# Common
# =============================================================================
install: ## Install deps
npm install -g @devcontainers/cli
pre-commit install --install-hooks
.PHONY: install
update: ## Update deps and tools
pre-commit autoupdate
.PHONY: update
# =============================================================================
# CI
# =============================================================================
ci: lint test ## Run CI tasks
.PHONY: ci
format: ## Run autoformatters
.PHONY: format
lint: ## Run all linters
.PHONY: lint
test: ## Run tests
devcontainer features test
.PHONY: test
# =============================================================================
# Handy Scripts
# =============================================================================
clean: ## Remove temporary files
.PHONY: clean