UNPKG

@lobehub/chat

Version:

Lobe Chat - an open-source, high-performance chatbot framework that supports speech synthesis, multimodal, and extensible Function Call plugin system. Supports one-click free deployment of your private ChatGPT/LLM web application.

15 lines (11 loc) 531 B
import { readMigrationFiles } from 'drizzle-orm/migrator'; import { writeFileSync } from 'node:fs'; import { join } from 'node:path'; const dbBase = join(__dirname, '../../src/database'); const migrationsFolder = join(dbBase, './migrations'); const migrations = readMigrationFiles({ migrationsFolder: migrationsFolder }); writeFileSync( join(dbBase, './client/migrations.json'), JSON.stringify(migrations, null, 2), // null, 2 adds indentation for better readability ); console.log('🏁 client migrations.json compiled!');