forked from mostly-ai/mostlyai-qa
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
32 lines (25 loc) · 806 Bytes
/
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
.PHONY: help
help: ## show definition of each function
@awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z1-9_-]+:.*?## / {printf "\033[36m%-25s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST)
.PHONY: clean
clean: ## remove .gitignore files
git clean -fdX
.PHONY: install
install: ## install dependencies
poetry install
.PHONY: lint
lint: ## run lints
poetry run pre-commit run --all-files
.PHONY: test
test: ## run tests
poetry run pytest
.PHONY: all
all: clean install lint test ## run all commands
.PHONY: build
build: ## build package
poetry build
twine check --strict dist/*
.PHONY: examples
examples: ## run all examples
find ./examples -maxdepth 1 -type f -name "*.ipynb" -print -execdir jupyter nbconvert --to script {} \;
find ./examples -maxdepth 1 -type f -name "*.py" -print -execdir python {} \;