-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
74 lines (57 loc) · 1.43 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
# See LICENSE file for copyright and license details.
# tumcsbot - https://github.com/ro-i/tumcsbot
# location to install the virtual environment
dest_dir = .
# bot parameters
args =
# run bot; default target
.PHONY: run
run:
@bash -- manage.sh -v run '$(dest_dir)' $(args)
.PHONY: class_diagram
class_diagram:
pyreverse --colorized -f ALL -S -my --ignore plugins src/tumcsbot -o svg
# run bot in debug mode
.PHONY: debug
debug: args = --debug
debug: run
# run in docker
.PHONY: docker-run
docker-run:
docker compose up
# run in docker in debug mode
.PHONY: docker-debug
docker-debug:
docker compose -f docker-compose.debug.yml up
# remove virtual environment
.PHONY: clean
clean:
@bash -- manage.sh -v clean '$(dest_dir)'
# install requirements (in virtualenv)
.PHONY: env
env:
@bash -- manage.sh -v env '$(dest_dir)'
.PHONY: init
init: database env
# prepare database
.PHONY: database
database:
@bash -- manage.sh -v database '$(dest_dir)'
# apply database migrations
migrations:
@bash -- manage.sh -v migrations '$(dest_dir)'
# run only mypy, not all static_analysis
.PHONY: mypy
mypy:
@bash -- manage.sh -v mypy '$(dest_dir)'
# run static analysis checker
.PHONY: static_analysis
static_analysis:
@bash -- manage.sh -v static_analysis '$(dest_dir)'
# run tests
.PHONY: tests
tests:
@bash -- manage.sh -v tests '$(dest_dir)'
.PHONY: upgrade_requirements
upgrade_requirements:
@bash -- manage.sh -v upgrade_requirements '$(dest_dir)'