-
-
Notifications
You must be signed in to change notification settings - Fork 14
/
Makefile
73 lines (48 loc) · 1.36 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
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
70
71
72
.PHONY: test
#
# qypws makefile
#
DEPTH=.
include $(DEPTH)/config.mk
DIST:=dist
MANIFEST=pyqgiswps/build.manifest
PYTHON_PKG=pyqgiswps pyqgisservercontrib
TESTDIR=tests/unittests
PYPISERVER:=storage
dirs:
mkdir -p $(DIST)
version:
echo $(VERSION_TAG) > VERSION
manifest: version
echo name=$(shell $(PYTHON) setup.py --name) > $(MANIFEST) && \
echo version=$(shell $(PYTHON) setup.py --version) >> $(MANIFEST) && \
echo buildid=$(BUILDID) >> $(MANIFEST) && \
echo commitid=$(COMMITID) >> $(MANIFEST)
deliver:
twine upload $(TWINE_OPTIONS) -r $(PYPISERVER) $(DIST)/*
dist: dirs manifest
rm -rf *.egg-info
$(PYTHON) -m build --no-isolation --sdist --outdir=$(DIST)
clean:
rm -rf $(DIST) *.egg-info
test: lint
make -C tests test PYTEST_ADDOPTS=$(PYTEST_ADDOPTS)
install:
pip install -U --upgrade-strategy=eager -e .
install-dev:
pip install -U --upgrade-strategy=eager -r requirements.dev
install-doc:
pip install -U --upgrade-strategy=eager -r doc/requirements.txt
lint:
@ruff check --output-format=concise $(PYTHON_PKG) $(TESTDIR)
lint-preview:
@ruff check --preview $(PYTHON_PKG) $(TESTDIR)
lint-fix:
@ruff check --preview --fix $(PYTHON_PKG) $(TESTDIR)
autopep8: lint-fix
typing:
mypy --config=$(topsrcdir)/mypy.ini -p pyqgiswps
client-test:
cd tests/clienttests && pytest -v $(PYTEST_ADDOPTS)
scan:
@bandit -c pyproject.toml -r pyqgiswps