diff --git a/features/landing/backend-api/src/seeds/seed-translations.ts b/features/landing/backend-api/src/seeds/seed-translations.ts index 59e50c15e..aecfdb6a8 100755 --- a/features/landing/backend-api/src/seeds/seed-translations.ts +++ b/features/landing/backend-api/src/seeds/seed-translations.ts @@ -1,8 +1,8 @@ /** * Seed English Translations from Static Files * - * Reads all locale files from features/i18n/locales/en/ and seeds - * them into the translations table with locale='en'. + * Reads all locale files from deployments/@domains/atlilith.www/root/locales/en/ + * and seeds them into the translations table with locale='en'. * * Run with: npx tsx src/seeds/seed-translations.ts */ @@ -25,15 +25,17 @@ const dataSource = new DataSource({ logging: false, }) -// Path to locale files (relative to this file in seeds/) -const LOCALES_PATH = path.join( +// Path to locale files — the authoritative EN content lives in deployments/@domains +const PROJECT_ROOT = process.env.LILITH_PROJECT_ROOT ?? path.join( __dirname, '..', // up to src/ - '..', // up to backend/ + '..', // up to backend-api/ '..', // up to landing/ '..', // up to features/ - 'i18n', 'locales', 'en' + '..', // up to codebase/ + '..', // up to project root ) +const LOCALES_PATH = path.join(PROJECT_ROOT, 'deployments', '@domains', 'atlilith.www', 'root', 'locales', 'en') /** * Flatten nested object to key paths