mirror of
https://github.com/catdevnull/preciazo.git
synced 2024-11-22 22:26:19 +00:00
11 lines
324 B
TypeScript
11 lines
324 B
TypeScript
|
import { Database } from "bun:sqlite";
|
||
|
import { drizzle } from "drizzle-orm/bun-sqlite";
|
||
|
import { DB_PATH } from "./drizzle.config.js";
|
||
|
import { migrateDb } from "./migrate.js";
|
||
|
import * as schema from "./schema.js";
|
||
|
|
||
|
migrateDb();
|
||
|
|
||
|
export const sqlite = new Database(DB_PATH);
|
||
|
export const db = drizzle(sqlite, { schema });
|