Files
pdfplumber/Makefile
T
Jeremy Singer-Vine cdfdb87a21 Enforce type annotations via mypy --strict
Enforcement added via:
- The repo's Makefile (`make check-mypy` & `make lint`)
- The repo's main GitHub Action
2022-05-06 09:51:01 -04:00

33 lines
709 B
Makefile

.PHONY: venv tests check-black check-flake lint format
PYTHON := venv/bin/python
PIP = venv/bin/pip
venv:
python3 -m venv venv
${PIP} install --upgrade pip
${PIP} install -r requirements.txt
${PIP} install -r requirements-dev.txt
${PIP} install -e .
tests:
${PYTHON} -m pytest
${PYTHON} -m coverage html
check-black:
${PYTHON} -m black --check pdfplumber tests
check-isort:
${PYTHON} -m isort --profile black --check-only pdfplumber tests
check-flake:
${PYTHON} -m flake8 pdfplumber tests
check-mypy:
${PYTHON} -m mypy --strict pdfplumber
lint: check-flake check-mypy check-black check-isort
format:
${PYTHON} -m black pdfplumber tests
${PYTHON} -m isort --profile black pdfplumber tests