Repository navigation
Expand file tree
/
Copy pathMakefile
More file actions
69 lines (56 loc) · 1.58 KB
/
Copy pathMakefile
File metadata and controls
69 lines (56 loc) · 1.58 KB
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
UV_RUN_DEV := uv run --with-requirements requirements.dev.txt
dist: clean ## builds source and wheel package
python setup.py sdist bdist_wheel
ls -l dist
.PHONY: clean
clean: clean-build clean-pyc clean-test ## remove all build, test, coverage and Python artifacts
.PHONY: clean-build
clean-build: ## remove build artifacts
rm -fr build/
rm -fr dist/
rm -fr .eggs/
find . -name '*.egg-info' -exec rm -fr {} +
find . -name '*.egg' -exec rm -f {} +
.PHONY: clean-test
clean-test: ## remove test and coverage artifacts
rm -fr .tox/
rm -f .coverage
rm -fr htmlcov/
rm -fr test_results/
rm -f result.xml
rm -rf prof/
.PHONY: clean-pyc
clean-pyc: ## remove Python file artifacts
find . -name '*.pyc' -exec rm -f {} +
find . -name '*.pyo' -exec rm -f {} +
find . -name '*~' -exec rm -f {} +
find . -name '__pycache__' -exec rm -fr {} +
.PHONY: test
test:
$(MAKE) format
$(MAKE) test-short
.PHONY: test-full
test-full:
$(UV_RUN_DEV) tox
.PHONY: test-short
test-short:
$(UV_RUN_DEV) tox -e py310
.PHONY: format
format:
$(UV_RUN_DEV) pre-commit run --all-files
.PHONY: release
release: dist ## package and upload release
uv pip install -qq twine
twine upload dist/*
.PHONY: release-test
release-test: dist ## package and upload test release
uv pip install -qq twine
twine upload --repository testpypi dist/*
.PHONY: bumpversion-to-dev
bumpversion-to-dev:
uv pip install -qq bumpversion==0.5.3
uv run python ./tools/bumpversion-tool.py --to-dev
.PHONY: bumpversion-from-dev
bumpversion-from-dev:
uv pip install -qq bumpversion==0.5.3
uv run python ./tools/bumpversion-tool.py --from-dev