-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
52 lines (38 loc) · 1.02 KB
/
Makefile
File metadata and controls
52 lines (38 loc) · 1.02 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
NAME := mapmaker
BASE := $(shell pwd)
DIST := file://$(BASE)/dist
BRANCH := $(shell git rev-parse --abbrev-ref HEAD)
.PHONY: build samples test
# Dependencies:
# sdist and wheel require the "build" package to be installed.
# install with `pip install build`
#
# check requires `twine` to be installed
build:
# build sdist and wheel
python -m build
sdist:
python -m build --sdist
wheel:
python -m build --wheel
check: build
# check the distribution
twine check dist/*
pypi: check-master clean check
# upload to PyPi, relies an ~/.pypirc for authentication
twine upload dist/*
check-master:
# make sure we are on the "master" branch
if [ "$(BRANCH)" != "master" ] ; then echo "not on master" && exit 1 ; fi
clean:
rm dist/* || true
dev-install:
pip install --no-deps --break-system-packages --editable .
samples:
mapmaker --zoom 10 --gallery 63.0695,-151.0074 30km ./samples
lint:
# use `pip install flake8`
flake8 ./mapmaker/*.py test/*.py
test:
# if tox is not installed, use `python -m unittest discover`
tox