You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
1.0 KiB

  1. .PHONY: run debug clean shell
  2. bin/activate: requirements.txt
  3. test -f bin/activate || $(shell which python3) -m venv .
  4. bin/pip install -Ur requirements.txt
  5. touch bin/activate
  6. run: bin/activate
  7. . bin/activate; FLASK_SETTINGS_FILE=../config/prod.cfg FLASK_ENV=production FLASK_APP=start.py flask run --host=0.0.0.0
  8. debug: bin/activate
  9. . bin/activate; FLASK_SETTINGS_FILE=../config/dev.cfg FLASK_ENV=development FLASK_APP=start.py flask run --host=0.0.0.0
  10. clean:
  11. rm -rf bin/ include/ lib/ lib64/ __pycache__/ share/; rm pyvenv.cfg
  12. shell: bin/activate
  13. . bin/activate; FLASK_SETTINGS_FILE=../config/dev.cfg FLASK_APP=start.py flask shell
  14. cli: bin/activate
  15. . bin/activate; FLASK_SETTINGS_FILE=../config/dev.cfg FLASK_APP=start.py flask ${COMMAND}
  16. recreatedb: bin/activate
  17. . bin/activate; FLASK_SETTINGS_FILE=../config/dev.cfg FLASK_APP=start.py flask acks dropdb
  18. . bin/activate; FLASK_SETTINGS_FILE=../config/dev.cfg FLASK_APP=start.py flask acks initdb
  19. . bin/activate; FLASK_SETTINGS_FILE=../config/dev.cfg FLASK_APP=start.py flask npc populate