-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
36 lines (31 loc) · 923 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
all: dist
.PHONY: dist
dist: veryclean venv/manifest.txt
./venv/bin/poetry build
.PHONY: lint
lint: venv/manifest.txt
./venv/bin/black --check .
./venv/bin/flake8 .
venv: venv/manifest.txt
venv/manifest.txt: ./pyproject.toml
rm -rf venv
python3 -m venv ./venv
PYTHONPATH= ./venv/bin/python3 -m pip install --upgrade pip
PYTHONPATH= ./venv/bin/python3 -m pip install --upgrade wheel poetry poetry-plugin-export
PYTHONPATH= ./venv/bin/poetry export --with dev --without-hashes --format=requirements.txt --output=requirements_tmp.txt
PYTHONPATH= ./venv/bin/python3 -m pip install --upgrade -r requirements_tmp.txt
PYTHONPATH= ./venv/bin/python3 -m pip freeze > $@
@echo ">> Venv prepared."
.PHONY: veryclean
veryclean: clean
veryclean:
rm -rf venv/
.PHONY: update_package
update_package: dist
python3 -m twine upload dist/*
.PHONY: clean
clean:
rm -rf build/
rm -rf logs/
rm -rf dist/
rm -rf *.egg-info