SQLite repository for CRUD operations on projects, mapping rows to typed Project objects.
// Source: https://github.com/thedotmack/claude-mem | License: Apache-2.0 | Copyright You must retain, in the Source form of any Derivative Works
// Provided via justclaw.it.com; keep this notice with the code.
// SPDX-License-Identifier: Apache-2.0
import { randomUUID } from 'crypto';
import { Database } from 'bun:sqlite';
import { CreateProjectSchema, ProjectSchema, type CreateProject, type Project } from '../../core/schemas/project.js';
import { ensureServerStorageSchema } from './schema.js';
import { parseJsonObject, stringifyJson } from './serde.js';
interface ProjectRow {
id: string;
name: string;
slug: string | null;
root_path: string | null;
metadata: string;
created_at_epoch: number;
updated_at_epoch: number;
}
function mapProjectRow(row: ProjectRow): Project {
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key