# Development Setup Guide ## Prerequisites - Python (version 3.10+) - PostgreSQL (version 13+) - Git ## Clone and Project Setup ```powershell # Clone the repository git clone https://git.allucanget.biz/allucanget/calminer.git cd calminer ``` ## Virtual Environment ```powershell # Create and activate a virtual environment python -m venv .venv .\.venv\Scripts\Activate.ps1 ``` ## Install Dependencies ```powershell pip install -r requirements.txt ``` ## Database Setup 1. Create database user: ```sql CREATE USER calminer_user WITH PASSWORD 'your_password'; ``` 2. Create database: ```sql CREATE DATABASE calminer; ``` ## Environment Variables 1. Copy `.env.example` to `.env` at project root. 2. Edit `.env` to set database connection string: ```dotenv DATABASE_URL=postgresql://:@localhost:5432/calminer ``` 3. The application uses `python-dotenv` to load these variables. ## Running the Application ```powershell # Start the FastAPI server uvicorn main:app --reload ``` ## Testing ```powershell pytest ``` ## Frontend Setup (TBD - add when frontend implemented)