Files
orangecat/scripts
Georgy ButaevandClaude Opus 4.8 56c231872f fix(design+infra): eliminate /400 opacity leaks + auto-apply migrations on deploy (P0)
Design: the `bg-surface-raised/400` class (Tailwind opacity caps at /100, so it was
silently dropped) appeared 11×. Where paired with text-white it was invisible in light
mode (blog filter chips, own-message bubble) → switched to the inverting
bg-fg-primary/text-fg-inverted pill. The rest (badges, dots, progress, a /400/10 double
typo, a raw hover:bg-gray-600) → valid semantic classes. Site-wide invalid-opacity
count now 0.

Infra P0 (the migration-drift root cause behind this session's 500s): the self-host had
NO migration tracking, so the box drifted from supabase/migrations/* and I hand-psql'd
~10 fixes. Now: a public.schema_migrations table (backfilled with the 147 existing
migrations) + deploy-selfhost.sh applies any unrecorded *.sql to the box, in order,
before boot-test, ON_ERROR_STOP + abort-on-fail. No more manual migrations or silent drift.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-18 18:08:13 +02:00
..
2025-12-10 16:56:40 +01:00
2025-12-10 16:56:40 +01:00

Scripts Directory

This directory contains all automation scripts organized by purpose.

Directory Structure

  • analysis/ - Bundle analysis, documentation checking, and optimization tools
  • auth-fix/ - Scripts to fix authentication and RLS policy issues
  • db/ - Database operations, migrations, and schema management
    • Migration scripts moved from root: apply-migration.js, apply-*-migration.js
    • Old schema files archived in db/archive/
  • deployment/ - Deployment, production setup, and monitoring scripts
  • dev/ - Development helpers, local setup, and debugging tools
  • diagnostics/ - Health checks and system diagnostics
  • maintenance/ - Cleanup, optimization, and maintenance scripts
  • monitoring/ - Performance monitoring and bundle size tracking
  • oauth/ - OAuth provider setup and configuration
  • profile-fix/ - Scripts to fix profile-related issues
  • schema-fix/ - Database schema fixes and migrations
  • storage/ - Supabase storage bucket setup and management
  • test/ - Testing utilities and validation scripts
    • Test/debug scripts moved from root: test-*.js, check-*.js, debug-*.js

Usage

Most scripts can be run with:

node scripts/{category}/script-name.js

For deployment scripts:

bash scripts/deployment/script-name.sh

Important Scripts

  • scripts/dev/dev-start.js - Main development server starter
  • scripts/deployment/browser-verify.js - Post-deploy browser smoke test (deploys themselves happen on the box — see docs/deployment/DEPLOYMENT_PROCESS.md)
  • scripts/db/apply-migrations.ts - Database migrations
  • scripts/maintenance/cleanup-console-logs.ts - Remove console.log statements