Leave Localhost logoLeave LocalhostDocs

Installation

This repository is a Bun workspace managed by Turborepo. Install dependencies once at the repository root.

This repository is a Bun workspace managed by Turborepo. Install dependencies once at the repository root.

Required Tooling

  • Bun 1.2.22, as declared by the root package.json.
  • Git.
  • A shell that can run the project scripts.

Install Bun from the official Bun installation guide, then confirm it is available:

bun --version

Install Dependencies

From the repository root:

bun install

This installs dependencies for all workspaces:

  • apps/app
  • apps/marketing
  • packages/*
  • tooling/*

The lockfile is bun.lock. Keep it committed when dependency changes are intentional.

Package Manager Rules

Use these commands in docs, scripts, and day-to-day work:

bun install
bun run <script>
bun --cwd <workspace> <script>
bunx <cli>

Do not introduce npm, pnpm, yarn, or npx commands unless there is a specific compatibility reason.

Common Root Scripts

bun dev
bun dev:app
bun dev:web
bun dev:convex
bun dev:email
bun run lint
bun run typecheck
bun run test
bun run build

The root scripts delegate to Turborepo so package tasks can run with the right dependency order and cache behavior.

Focused Workspace Commands

Use bun --cwd when you need to run a workspace command directly:

bun --cwd apps/app build
bun --cwd apps/marketing build
bun --cwd packages/backend test
bun --cwd packages/email dev

Prefer root commands for normal verification. Use focused commands when you are working in one package or debugging a package-specific failure.

Generated Directories

These directories are local build output and should not be committed:

  • .next
  • .turbo
  • .react-email
  • node_modules
  • generated package caches

If install or build state becomes stale, remove generated output through the existing clean scripts instead of deleting source files:

bun clean:workspaces

The root clean script removes node_modules through git clean. Read the script before running it if you have untracked local files.

On this page