-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
40 lines (32 loc) · 1011 Bytes
/
Makefile
File metadata and controls
40 lines (32 loc) · 1011 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
38
39
40
# Makefile for Forecasting Service
.PHONY: setup install run migrate test help
# Variables
PYTHON = python
VENV = venv
MANAGE = $(PYTHON) manage.py
PIP = pip
DIR = cd forecast_system
help:
@echo "Available commands:"
@echo " setup - Create virtual environment"
@echo " install - Install dependencies"
@echo " run - Run development server"
@echo " migrate - Run database migrations"
@echo " test - Run tests"
@echo " lint - Run linting checks"
@echo " coverage - Run tests with coverage report"
@echo " clean - Remove cached files"
setup:
$(PYTHON) -m venv $(VENV)
@echo "Virtual environment created. Activate with:"
@echo " source $(VENV)/bin/activate (Linux/macOS)"
@echo " .\\$(VENV)\\Scripts\\activate (Windows)"
install:
$(PIP) install -r requirements.txt
run:
$(DIR) && $(MANAGE) runserver
migrate:
$(DIR) && $(MANAGE) makemigrations
$(DIR) && $(MANAGE) migrate
test:
$(DIR) && $(MANAGE) test