import { config } from "dotenv";
import { drizzle } from "drizzle-orm/node-postgres";
import { resolve } from "path";
import { fileURLToPath } from "url";
import { dirname } from "path";

config({
  path: resolve(dirname(fileURLToPath(import.meta.url)), "../../../.env"),
});

export const db = drizzle(process.env["DATABASE_URL"]!);
