chore: rename project from glossa to lila
- Update all package names from @glossa/* to @lila/* - Update all imports, container names, volume names - Update documentation references - Recreate database with new credentials
This commit is contained in:
parent
1699f78f0b
commit
3f7bc4111e
37 changed files with 116 additions and 182 deletions
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"name": "@glossa/api",
|
||||
"name": "@lila/api",
|
||||
"version": "1.0.0",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
|
|
@ -10,8 +10,8 @@
|
|||
"test": "vitest"
|
||||
},
|
||||
"dependencies": {
|
||||
"@glossa/db": "workspace:*",
|
||||
"@glossa/shared": "workspace:*",
|
||||
"@lila/db": "workspace:*",
|
||||
"@lila/shared": "workspace:*",
|
||||
"better-auth": "^1.6.2",
|
||||
"cors": "^2.8.6",
|
||||
"express": "^5.2.1"
|
||||
|
|
|
|||
|
|
@ -1,12 +1,9 @@
|
|||
import { describe, it, expect, vi, beforeEach } from "vitest";
|
||||
import request from "supertest";
|
||||
|
||||
vi.mock("@glossa/db", () => ({
|
||||
getGameTerms: vi.fn(),
|
||||
getDistractors: vi.fn(),
|
||||
}));
|
||||
vi.mock("@lila/db", () => ({ getGameTerms: vi.fn(), getDistractors: vi.fn() }));
|
||||
|
||||
import { getGameTerms, getDistractors } from "@glossa/db";
|
||||
import { getGameTerms, getDistractors } from "@lila/db";
|
||||
import { createApp } from "../app.js";
|
||||
|
||||
const app = createApp();
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import type { Request, Response, NextFunction } from "express";
|
||||
import { GameRequestSchema, AnswerSubmissionSchema } from "@glossa/shared";
|
||||
import { GameRequestSchema, AnswerSubmissionSchema } from "@lila/shared";
|
||||
import { createGameSession, evaluateAnswer } from "../services/gameService.js";
|
||||
import { ValidationError } from "../errors/AppError.js";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import { betterAuth } from "better-auth";
|
||||
import { drizzleAdapter } from "better-auth/adapters/drizzle";
|
||||
import { db } from "@glossa/db";
|
||||
import * as schema from "@glossa/db/schema";
|
||||
import { db } from "@lila/db";
|
||||
import * as schema from "@lila/db/schema";
|
||||
|
||||
export const auth = betterAuth({
|
||||
database: drizzleAdapter(db, { provider: "pg", schema }),
|
||||
|
|
|
|||
|
|
@ -1,12 +1,9 @@
|
|||
import { describe, it, expect, vi, beforeEach } from "vitest";
|
||||
import type { GameRequest, AnswerSubmission } from "@glossa/shared";
|
||||
import type { GameRequest, AnswerSubmission } from "@lila/shared";
|
||||
|
||||
vi.mock("@glossa/db", () => ({
|
||||
getGameTerms: vi.fn(),
|
||||
getDistractors: vi.fn(),
|
||||
}));
|
||||
vi.mock("@lila/db", () => ({ getGameTerms: vi.fn(), getDistractors: vi.fn() }));
|
||||
|
||||
import { getGameTerms, getDistractors } from "@glossa/db";
|
||||
import { getGameTerms, getDistractors } from "@lila/db";
|
||||
import { createGameSession, evaluateAnswer } from "./gameService.js";
|
||||
|
||||
const mockGetGameTerms = vi.mocked(getGameTerms);
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import { randomUUID } from "crypto";
|
||||
import { getGameTerms, getDistractors } from "@glossa/db";
|
||||
import { getGameTerms, getDistractors } from "@lila/db";
|
||||
import type {
|
||||
GameRequest,
|
||||
GameSession,
|
||||
|
|
@ -7,7 +7,7 @@ import type {
|
|||
AnswerOption,
|
||||
AnswerSubmission,
|
||||
AnswerResult,
|
||||
} from "@glossa/shared";
|
||||
} from "@lila/shared";
|
||||
import { InMemoryGameSessionStore } from "../gameSessionStore/index.js";
|
||||
import { NotFoundError } from "../errors/AppError.js";
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue