-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathMakefile
49 lines (37 loc) · 1.04 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
40
41
42
43
44
45
46
47
48
49
package := "todoist-analytics"
# launch streamlit app
get_token:
read token; \
echo "token = " \"$$token\" > "./todoist_analytics/credentials.py"
credentials:
[ -f ./todoist_analytics/credentials.py ] && echo credentials ok || $(MAKE) get_token
app:
poetry run streamlit run streamlit_app.py --server.port 7070
# black and isort
lint:
poetry run black .
poetry run isort .
checks:
@poetry run flake8 .
@poetry run vulture todoist_analytics
@poetry run poetry check
@poetry run safety check --full-report
# build documentation
docs:
poetry run sphinx-build -a docs docs/site
# show documentation in browser
show:
start docs/site/index.html
# publish documentation to Github Pages
pages:
poetry run ghp-import docs/site
# create rst source for API documentation
apidoc:
sphinx-apidoc -o docs src/{{package}}
container:
@poetry build
@docker build -t todoist_analytics .
@docker run -p 8080:8080 todoist_analytics
heroku:
@heroku container:push web --app todoist-analytics-mvp
@heroku container:release web --app todoist-analytics-mvp