diff --git a/web/README.md b/web/README.md index 0faed4e..2b5e7c5 100644 --- a/web/README.md +++ b/web/README.md @@ -45,7 +45,6 @@ sudo service postgresql enable We will now create a database and user to work with - ``` sudo -u postgres psql ``` @@ -83,7 +82,6 @@ Now you need to fill out an environment file for local development. Create a `.e DATABASE_URL=postgresql://bwcontest:pass123@127.0.0.1:5432/bwcontest ``` - You now need to push the schema generated via the Prisma ORM to set up the tables in the database. This can be done by running... ```bash diff --git a/web/src/routes/admin/contests/util.ts b/web/src/lib/server/repos.ts similarity index 100% rename from web/src/routes/admin/contests/util.ts rename to web/src/lib/server/repos.ts diff --git a/web/src/routes/admin/contests/[contestId]/+page.server.ts b/web/src/routes/admin/contests/[contestId]/+page.server.ts index 22557cb..f27069a 100644 --- a/web/src/routes/admin/contests/[contestId]/+page.server.ts +++ b/web/src/routes/admin/contests/[contestId]/+page.server.ts @@ -3,7 +3,7 @@ import type { PageServerLoad } from './$types'; import { db } from '$lib/server/prisma'; import fs from 'fs-extra'; import { join } from 'path'; -import { createRepos } from '../util'; +import { createRepos } from '$lib/server/repos'; export const load = (async ({ params }) => { const contestId = parseInt(params.contestId); diff --git a/web/src/routes/admin/contests/create/+page.server.ts b/web/src/routes/admin/contests/create/+page.server.ts index dd670db..833099b 100644 --- a/web/src/routes/admin/contests/create/+page.server.ts +++ b/web/src/routes/admin/contests/create/+page.server.ts @@ -1,6 +1,6 @@ import { db } from '$lib/server/prisma'; +import { createRepos } from '$lib/server/repos'; import type { Actions, PageServerLoad } from './$types'; -import { createRepos } from '../util'; export const load = (async () => { const teams = await db.team.findMany();