-
Notifications
You must be signed in to change notification settings - Fork 108
/
Makefile
39 lines (31 loc) · 1.06 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
.PHONY: lint test install format all develop shell help
POETRY ?= poetry run
help:
@echo -e "Task runner for python-tidal. Run make <option> to do something.\n"
@echo -e "\t\t\tOptions\n"
@echo -e "develop:\tset up development virtual environment with required deps"
@echo -e "shell:\t\tstart a shell inside the development environment"
@echo -e "install:\tbuild package and install system wide (do not run this from within the virtual environment)"
@echo -e "format:\t\tformat code"
@echo -e "lint:\t\tlint code"
@echo -e "test:\t\trun tests: will fail if development environment not already created"
develop:
poetry install
shell:
poetry shell
install:
rm -rf dist
poetry build
pip install dist/*.whl
format:
${POETRY} isort tidalapi tests
${POETRY} black tidalapi tests
${POETRY} docformatter -i tidalapi tests
# ${POETRY} ruff . # Don't autofix as ruff can break things
lint:
${POETRY} isort --check tidalapi tests
${POETRY} black --check tidalapi tests
${POETRY} docformatter --check tidalapi tests
# ${POETRY} ruff .
test:
${POETRY} pytest tests/