-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathMakefile
More file actions
37 lines (27 loc) · 785 Bytes
/
Makefile
File metadata and controls
37 lines (27 loc) · 785 Bytes
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
clean: clean-pyc
clean-pyc:
@find . -name '*.pyc' -exec rm -f {} +
@find . -name '*.pyo' -exec rm -f {} +
@find . -name '*~' -exec rm -f {} +
@find . -name '__pycache__' -exec rm -fr {} +
ifeq (server,$(firstword $(MAKECMDGOALS)))
# use the rest as arguments for "serve"
RUN_ARGS := $(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
# ...and turn them into do-nothing targets
$(eval $(RUN_ARGS):;@:)
endif
server:
postflow $(RUN_ARGS)
serve:
@$(MAKE) server run
admin-serve:
@npm run dev --prefix admin
admin-build:
@npm run build --prefix admin && rm -rf postflow/admin/static/* && cp -r admin/dist/* postflow/admin/static
dev:
@$(MAKE) serve admin-serve -j 2
dependencies:
pip install -r requirements.txt
install: dependencies
clear
postflow init