Initial commit: Complete project-bootstrap tool
- Bootstrap script for creating monorepo projects - FastAPI backend templates with uv, ruff, mypy, pytest - React frontend templates with TypeScript, ESLint, Prettier - Docker Compose setup with backend, frontend, and database - 9 development and CI scripts - Gitea Actions CI/CD workflows - Comprehensive documentation (8 files) - 45 template files for complete project structure - Automated verification script (all tests pass) - Based on coding-agent-rules standards
This commit is contained in:
31
templates/scripts/dev/start-backend.sh
Executable file
31
templates/scripts/dev/start-backend.sh
Executable file
@@ -0,0 +1,31 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Start backend development server
|
||||
|
||||
set -e
|
||||
|
||||
cd "$(dirname "$0")/../../backend"
|
||||
|
||||
echo "Starting backend server..."
|
||||
|
||||
if [ ! -f ".env" ]; then
|
||||
echo "Creating .env from .env.example..."
|
||||
cp .env.example .env
|
||||
fi
|
||||
|
||||
# Check if uv is installed
|
||||
if ! command -v uv &> /dev/null; then
|
||||
echo "Error: uv is not installed. Please install it first."
|
||||
echo "Visit: https://github.com/astral-sh/uv"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Install dependencies if needed
|
||||
if [ ! -d ".venv" ]; then
|
||||
echo "Installing dependencies..."
|
||||
uv sync
|
||||
fi
|
||||
|
||||
# Start the server
|
||||
echo "Starting uvicorn..."
|
||||
uv run uvicorn app.main:app --reload --host 0.0.0.0 --port 8000
|
||||
Reference in New Issue
Block a user