forked from hearsaycorp/richenum
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
37 lines (26 loc) · 942 Bytes
/
Makefile
File metadata and controls
37 lines (26 loc) · 942 Bytes
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
REPO = $(shell git rev-parse --show-toplevel)
POETRY = poetry
.PHONY: hooks install-build install-dev poetry quickstart quickstart-build clean lint test build
hooks:
${REPO}/githooks/update_githooks.sh
install-build: poetry
${POETRY} install --only=main --sync
install-dev: poetry
${POETRY} install --with dev --sync
poetry:
curl -sSL https://install.python-poetry.org | POETRY_VERSION=2.2.1 python3 -
poetry cache clear pypi --all
poetry config virtualenvs.in-project true
quickstart: poetry install-dev hooks
quickstart-build: poetry install-build hooks
clean:
# Delete all .pyc and .pyo files.
find ${REPO} \( -name "*~" -o -name "*.py[co]" -o -name ".#*" -o -name "#*#" \) -exec rm '{}' +
rm -rf .pytest_cache
lint: clean
${POETRY} run flake8 --config=${REPO}/.flake8 ${REPO}/src/richenum
${POETRY} run pylint --rcfile=${REPO}/pylint.rc ${REPO}/src/richenum
test: clean
${POETRY} run pytest
build:
${POETRY} build