-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
42 lines (33 loc) · 962 Bytes
/
Makefile
File metadata and controls
42 lines (33 loc) · 962 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
SHELL := bash
.ONESHELL:
.SHELLFLAGS := -eu -o pipefail -c
MAKEFLAGS += --warn-undefined-variables
MAKEFLAGS += --no-builtin-rules
.PHONY: help
help: ## Print this help message
@echo -e "$$(grep -hE '^\S+:.*##' $(MAKEFILE_LIST) | sed -e 's/:.*##\s*/:/' -e 's/^\(.\+\):\(.*\)/\\x1b[36m\1\\x1b[m:\2/' | column -c2 -t -s :)"
.PHONY: init
init: # Install all dependencies
pip install -IUr requirements.txt -r requirements-dev.txt
.PHONY: clean
clean: ## Clean project
rm -rf .ruff_cache/ .mypy_cache/ node_modules/ .direnv/ .venv/
.PHONY: check-format
check-format: ## Check code formatting
black --check .
.PHONY: format
format: ## Fix code formatting
black .
.PHONY: typecheck
typecheck: ## Check code types
mypy main.py
mypy tests
.PHONY: lint
lint: ## Lint code
ruff check main.py tests
.PHONY: test
test: ## Run unit-test
python -m pytest
.PHONY: docker-image
docker-build: # Build Docker image
docker build -f Dockerfile -t setup-matrix .