32 lines
906 B
Bash
Executable File
32 lines
906 B
Bash
Executable File
#!/bin/bash
|
|
# Standalone API Evolution Check Script
|
|
# This script only checks for API evolution without regenerating types.
|
|
# Useful for quick checks during development.
|
|
|
|
set -e
|
|
|
|
echo "🔍 API Evolution Check"
|
|
echo "======================"
|
|
|
|
# Change to the project directory
|
|
cd "$(dirname "$0")"
|
|
|
|
# Check if schema file exists
|
|
if [ ! -f "client/openapi-schema.json" ]; then
|
|
echo "❌ OpenAPI schema not found. Run ./generate-ts-types.sh first."
|
|
exit 1
|
|
fi
|
|
|
|
# Check if the frontend container is running
|
|
if ! docker compose ps static-frontend | grep -q "Up"; then
|
|
echo "📋 Starting frontend container..."
|
|
docker compose up -d static-frontend
|
|
fi
|
|
|
|
echo "📋 Running API evolution check..."
|
|
docker compose exec static-frontend node check-api-evolution.js
|
|
|
|
echo ""
|
|
echo "💡 To regenerate types and schema: ./generate-ts-types.sh"
|
|
echo "💡 To run this check only: ./check-api-evolution.sh"
|