-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmakefile
50 lines (36 loc) · 1.16 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
settings=scts.settings.scts_settings
export DJANGO_SETTINGS_MODULE=$(settings)
export PYTHONPATH=$(shell pwd)/
run:
pipenv run gunicorn -b 0.0.0.0:8000 scts:app --worker-class aiohttp.GunicornUVLoopWebWorker --reload
check:
isort scts tests
flake8 scts tests
install:
pip install pipenv
pipenv install --dev
uninstall-all:
pip freeze | xargs pip uninstall -y
migrations:
django-admin makemigrations
migrate:
django-admin migrate
test:
pipenv run pytest -s -x --cov=scts --cov-config=setup.cfg --cov-report term-missing $(path)
release-patch: ## Create a patch release
@bumpversion patch
git push --follow-tags
release-minor: ## Create a minor release
@bumpversion minor
release-major: ## Create a major release
@bumpversion major
coveralls:
coverage run --source=scts/ --rcfile=setup.cfg -m pytest tests
coveralls --rcfile=setup.cfg
generate-docs:
python docs/architecture_doc.py
docker-build:
@docker rmi -f scts
@docker build --tag scts .
docker-run: # Run in background
@docker start scts || (echo "No container found." && echo "Running new container..." && docker run -d --publish 8000:8000 --name scts scts && echo "Container created and running!")