Ken Tandrian eb26707e8c
Feature/migrate seed.js to TypeScript (#4248)
* feat(db): migrate seed.js to typescript

* feat(db): change seed command

* Update changelog
2025-01-27 20:24:30 +01:00

25 lines
428 B
TypeScript

import { PrismaClient } from '@prisma/client';
const prisma = new PrismaClient();
async function main() {
await prisma.tag.createMany({
data: [
{
id: '4452656d-9fa4-4bd0-ba38-70492e31d180',
name: 'EMERGENCY_FUND'
}
],
skipDuplicates: true
});
}
main()
.catch((e) => {
console.error(e);
process.exit(1);
})
.finally(async () => {
await prisma.$disconnect();
});