-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathMakefile
37 lines (30 loc) · 830 Bytes
/
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
FORMAT_DIR = src
release_from-develop:
gh pr create --base main --head develop --title "Release v$(version)"
gh pr merge --auto
gh release create $(version) --target main --latest --generate-notes --title "$(version)"
build:
rm -rf dist
pip install -e .[build]
python -m build
release:
echo "Releasing version $(version)"
make format
make lint
git add .
git commit -m 'release: $(version)' --allow-empty
git push origin develop
make release_from-develop version=$(version)
commit:
make format
git add .
git commit -m '$(message)'
format:
pip install -e .[format]
python -m isort $(FORMAT_DIR)
python -m black $(FORMAT_DIR)
lint:
pip install -e .[lint]
python -m flake8 $(FORMAT_DIR)
python -m mypy $(FORMAT_DIR) --install-types --non-interactive
PHONY: build release release_from-develop format commit