-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
40 lines (34 loc) · 911 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
33
34
35
36
37
38
39
40
PROJECT = enigma_rsa
VIRTUAL_ENV = env
install: virtual download_and_activate prepare
virtual:
@echo "--> Setup and activate virtualenv"
if test -d "$(VIRTUAL_ENV)"; then \
rm -rf $(VIRTUAL_ENV); \
fi
if test ! -d "$(VIRTUAL_ENV)"; then \
pip3 install virtualenv; \
virtualenv -p python3 $(VIRTUAL_ENV); \
fi
@echo ""
download_and_activate:
@echo "-->Activating virtual environment"
if test -d "$(VIRTUAL_ENV)"; then \
. ./$(VIRTUAL_ENV)/bin/activate; \
pip3 install -r requirements.txt; \
fi
@echo "Now type 'source ./env/bin/activate'"
prepare:
@echo "Preparing chat environment"
if test -d "$(VIRTUAL_ENV)"; then \
. ./$(VIRTUAL_ENV)/bin/activate; \
python3 ./chat_files/main.py; \
fi
reboot:
if test ! -d "$(VIRTUAL_ENV)"; then \
exit 2; \
fi
if test -d "chat_files"; then \
. ./$(VIRTUAL_ENV)/bin/activate; \
python3 chat_files/main.py; \
fi