inital commit
This commit is contained in:
4
run/db_deleteall.ts
Normal file
4
run/db_deleteall.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import * as db from "../app/sql";
|
||||
|
||||
const query = db.db.query("DELETE FROM events;");
|
||||
query.run();
|
||||
9
run/db_init.ts
Normal file
9
run/db_init.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
import { Event } from "../app/component/event/events";
|
||||
import * as db from "../app/sql";
|
||||
import { Database } from "bun:sqlite";
|
||||
|
||||
export function init ( db: Database ) {
|
||||
Event.createTable( db );
|
||||
};
|
||||
|
||||
init(db.db);
|
||||
Reference in New Issue
Block a user