Developer
Contributing
How to set up a development environment and contribute to Retrace.
Prerequisites
- macOS 12+ (Tauri builds target macOS)
- Bun (runtime for the server)
- Node.js 22+ (for frontend tooling)
- Rust (for Tauri native shell)
Clone and install
git clone https://github.com/aballiet/retrace.git
cd retrace
bun installDevelopment
Start the API server and frontend in development mode:
# Terminal 1: API server
cd packages/server
bun run dev
# Terminal 2: Frontend
cd packages/app
bun run devThe frontend runs on localhost:1420 with hot reload. The API server restarts on file changes.
Project layout
packages/
app/ React frontend (Vite + React Router)
src/
pages/ Route pages
components/ UI components
server/ Bun API server (Hono)
src/
routes/ API route handlers
consumers/ MCP server, ingest pipeline
db/ Drizzle schema + migrationsDatabase migrations
Retrace uses Drizzle ORM for schema management:
cd packages/server
bun run db:generate # Generate migration from schema changes
bun run db:migrate # Apply pending migrationsAdding a new import source
- Create a parser in
packages/server/src/parsers/ - Add the platform to the unified import route in
routes/import-unified.ts - Add a card in the frontend import UI
- Write a docs page in
retrace-site/docs/content/docs/import/
Running tests
bun testCode style
- TypeScript throughout (server + frontend)
- Functional components with hooks (React)
- Hono route handlers return JSON
- Drizzle for all database queries (no raw SQL)
Submitting changes
- Fork the repo and create a branch
- Make your changes
- Run tests
- Open a pull request against
main
See GitHub Issues for things to work on.