import "dotenv/config";
import type { Config } from "drizzle-kit";

export default {
  schema: "./src/db/schema.ts",
  out: "./src/db/migrations",
  // driver: process.env.DB_DRIVER, // 'pg' | 'mysql2' | 'better-sqlite' | 'libsql' | 'turso'
  dialect: "mysql",
  dbCredentials: {
    host: process.env.DB_SERVER ?? "localhost",
    user: process.env.DB_USERNAME ?? "root",
    port: (process.env.DB_PORT as number | undefined) ?? 3302,
    password: process.env.DB_PASSWORD,
    database: process.env.DB_NAME ?? "sambekiel",
  },
  introspect: {
    casing: "preserve",
  },
  verbose: true,
} satisfies Config;
