#!/bin/bash

# Authentication System - Development Server Script
# Start the application with auto-reload

clear
echo "=================================="
echo "Authentication System"
echo "Starting development server..."
echo "=================================="
echo ""

# Check if node_modules exists
if [ ! -d "node_modules" ]; then
    echo "node_modules not found. Installing dependencies..."
    npm install
    echo ""
fi

# Check if .env exists
if [ ! -f ".env" ]; then
    echo "Warning: .env file not found. Please create it before running."
    echo "Copy .env.example to .env and configure it."
    exit 1
fi

# Start the application
npm run dev
