Archivist is a platform where you can make daily journal entries with custom categories.
Design by: Satyam Vyas
Frontend code by: Karan
Code assistance: Blackbox AI
- TypeScript - For type safety and improved developer experience
- Next.js - Full-stack React framework
- TailwindCSS - Utility-first CSS for rapid UI development
- shadcn/ui - Reusable UI components
- Express - Fast, unopinionated web framework
- Bun - Runtime environment
- Drizzle - TypeScript-first ORM
- PostgreSQL - Database engine
- Authentication - Better-Auth
- Turborepo - Optimized monorepo build system
Follow these steps to get the project running on your local machine.
- Bun (latest version)
- PostgreSQL database
Install the project dependencies using Bun:
bun install-
Copy the example environment file:
cp apps/server/.env.example apps/server/.env
-
Update
apps/server/.envwith your configuration:DATABASE_URL: Connection string for your PostgreSQL database.BETTER_AUTH_SECRET: A secure random string for authentication.BETTER_AUTH_URL:http://localhost:3003(Frontend URL).CORS_ORIGIN:http://localhost:3003(Frontend URL).GOOGLE_CLIENT_ID: Google OAuth client ID.GOOGLE_CLIENT_SECRET: Google OAuth client secret.
Note: You can get the
GOOGLE_CLIENT_IDandGOOGLE_CLIENT_SECRETfrom the Google Cloud Console.Google OAuth Configuration:
- Authorized JavaScript origins:
http://localhost:3003 - Authorized redirect URIs:
http://localhost:3009/api/auth/callback/google
For more details, see the Better Auth Installation Guide.
- Copy the example environment file:
cp apps/web/.env.example apps/web/.env
- Update
apps/web/.env:NEXT_PUBLIC_SERVER_URL:http://localhost:3009(Backend API URL).NEXT_PUBLIC_FRONTEND_URL:http://localhost:3003.
Once your .env is configured and your Postgres database is running, push the schema:
bun run db:pushYou can also open the database studio to view your tables:
bun run db:studioStart both the frontend and backend in development mode:
bun run dev- Frontend: http://localhost:3003
- Backend: http://localhost:3009
archivist/
├── apps/
│ ├── web/ # Frontend application (Next.js)
│ └── server/ # Backend API (Express)
├── packages/
│ ├── api/ # API layer / business logic
│ ├── auth/ # Authentication configuration & logic
│ └── db/ # Database schema & queries
bun run dev: Start all applications in development modebun run build: Build all applicationsbun run dev:web: Start only the web applicationbun run dev:server: Start only the serverbun run check-types: Check TypeScript types across all appsbun run db:push: Push schema changes to databasebun run db:studio: Open database studio UI
We use a feature branch workflow for contributions. Please follow these steps:
- Fork this repository to your GitHub account
- Clone your fork locally:
git clone https://github.com/ramxcodes/archivist.git cd archivist
-
Install dependencies:
bun install
-
Set up your environment variables:
cp apps/server/.env.example apps/server/.env
Update the
.envfile with your database credentials. -
Set up the database:
bun run db:push
Create a new branch for your feature or bug fix:
git checkout -b feature/your-feature-name- Keep changes scoped and incremental; smaller PRs are easier to review.
- If you touch the database schema, update the Drizzle schema and push it to your local database with
bun run db:push. - Verify type safety and builds before opening a PR:
bun run check-types
bun run buildgit add .
git commit -m "feat: add short description of change"
git push origin feature/your-feature-nameUse clear, descriptive commit messages. Group unrelated changes into separate commits or branches.
- Open a PR against the main repository.
- Include a concise summary of the change, any notable decisions, and screenshots for UI updates.
- List the checks you ran (e.g.,
bun run check-types,bun run build).
- Prefer TypeScript with strict typings; add interfaces/types near their usage.
- Reuse existing shadcn/ui components and Tailwind utilities for consistency.
- Keep API contracts in sync between
apps/serverandapps/web; update shared types inpackages/apiwhen needed. - For database changes, keep Drizzle schema and migrations consistent and document any data backfill steps in the PR.