-
Notifications
You must be signed in to change notification settings - Fork 23
/
Makefile
55 lines (39 loc) · 1.19 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
.PHONY: docs test
help:
@echo " env create a development environment using virtualenv"
@echo " deps install dependencies using pip"
@echo " clean remove unwanted files like .pyc's"
@echo " lint check style with flake8"
@echo " test run all your tests using py.test"
env:
virtualenv -p /usr/local/bin/python3 venv && \
. venv/bin/activate && \
make deps
deps:
pip install -r requirements.txt
clean:
python manage.py clean
lint:
flake8 --exclude=venv,app/static .
test:
py.test tests
local:
source venv/bin/activate && ./manage.py runserver
dev:
source venv/bin/activate && uwsgi --ini uwsgi.ini --py-autoreload 1
prod:
source venv/bin/activate && uwsgi --ini uwsgi.ini
createdb:
source venv/bin/activate && python manage.py createdb
babelextract:
source venv/bin/activate && \
pybabel extract -F app/babel.cfg -k lazy_gettext -o app/messages.pot app
babelcompile:
source venv/bin/activate && pybabel compile -d app/translations
# German
germaninit:
source venv/bin/activate && \
pybabel init -i app/messages.pot -d app/translations -l de
germanupdate:
source venv/bin/activate && \
pybabel update -i app/messages.pot -d app/translations -l de