-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
43 lines (33 loc) · 1.56 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
SHELL := /usr/bin/env bash
MAKEFLAGS += -j1
include build-support/alpha-build/core/helpers.mk
include build-support/alpha-build/core/resolver.mk # Utilities to resolve targets
PY_SOURCES_ROOTS=art_deco/
include build-support/alpha-build/core/python/pythonpath.mk # Let AlphaBuild set PYTHONPATH based on PY_SOURCES_ROOTS
include build-support/alpha-build/core/multi/pre-commit.mk
include build-support/alpha-build/core/python/test.mk
# Define where Python files live (for testing purposes)
ONPY=art_deco/ tests/
.PHONY: lint
lint: pre-commit-run # The pre-commit-run goal comes from AlphaBuild Core
.PHONY: test
test: pytest # The pytest goal comes from AlphaBuild Core
@echo "Check coverage on the diff between the main branch and the current revision"
$(python) -m diff_cover.diff_cover_tool coverage.xml --config-file=pyproject.toml --fail-under=85
# Uncomment the below to set specific test coverage requirements for specific sub-directories (usually stricter than the global setting)
# $(python) -m coverage report --include="art_deco/critical-module/*" --fail-under=95
.PHONY: env
env:
$(python) -m pip install --upgrade pip setuptools
$(python) -m pip install -r 3rdparty/requirements.txt -r 3rdparty/requirements-dev.txt -c 3rdparty/constraints.txt
.PHONY: env-upgrade
env-upgrade:
$(python) -m pip install --upgrade pip setuptools
$(python) -m pip install -r 3rdparty/requirements.txt -r 3rdparty/requirements-dev.txt
$(python) -m pip list --format=freeze > 3rdparty/constraints.txt
.PHONY: wheel
wheel:
$(python) -m build .
.PHONY: bump
bump:
$(python) -m bumpversion