File: makefile

package info (click to toggle)
python-inject 5.3.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 196 kB
  • sloc: python: 1,039; makefile: 28; sh: 5
file content (33 lines) | stat: -rw-r--r-- 887 bytes parent folder | download
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
SHELL               :=	bash
.DELETE_ON_ERROR:
.SHELLFLAGS         :=	-ceu
MAKEFLAGS           +=	--no-builtin-rules \
                        --warn-undefined-variables

.PHONY: dist pytest test

dist:
	if ! python3 -m pip freeze | grep -q build; then python3 -m pip install --upgrade build; fi
	python3 -m build --outdir=dist --sdist --wheel ./

install_dev:
	python3 -m pip install --upgrade pip
	python3 -m pip install --upgrade --editable=./

upload:
	if ! python3 -m pip freeze | grep -q twine; then python3 -m pip install --upgrade twine; fi
	python3 -m twine upload dist/*

clean:
	rm -rf ./build/*
	rm -rf ./dist/*
	rm -rf ./.mypy_cache
	rm -rf ./.pytest_cache

pytest:
	if ! command -v pytest &>/dev/null; then python3 -m pip install --upgrade pytest; fi
	pytest test

test:
	if ! command -v nosetests &>/dev/null; then python3 -m pip install --upgrade nose; fi
	nosetests test