Thank you for your interest in contributing to DireWork. This guide covers the setup and workflow for contributing.
- Bun v1.1+
- Docker (for PostgreSQL)
- Node.js v20+ (for Next.js runtime)
- A Twitch Developer Application for OAuth credentials
-
Fork and clone the repository:
git clone https://github.com/<your-username>/dirework.git cd dirework
-
Install dependencies:
bun install
-
Configure environment variables:
cp .env.example .env
Fill in the required values — see
.env.examplefor descriptions. -
Start the database:
bun run db:start
-
Push the schema (development only — creates tables without migrations):
bun run db:push
-
Start the dev server:
bun run dev
The web app runs at
http://localhost:3001and docs athttp://localhost:4000.
main— production branch, protecteddev— development branch
All work should be done on feature branches created from dev:
git checkout dev
git pull origin dev
git checkout -b feat/your-feature-name- Follow existing code patterns and conventions documented in
CLAUDE.md - Use TypeScript strict mode — no
anytypes - Use functional components with
"use client"where needed - Style with Tailwind utility classes
- Extract pure logic into testable modules (not inline in components/routers)
Run the full test suite before submitting:
bun run testRun type checking:
bun run check-typesRun a production build to catch build-time errors:
bun run buildWhen adding new pure functions, add corresponding tests in a __tests__/ directory alongside the source file.
- Ensure all checks pass:
bun run check-types && bun run test && bun run build - Create a PR from your feature branch to
dev - Provide a clear title and description of your changes
- Link any relevant issues
- Wait for review — maintainers may request changes
- No unused imports or variables
- No
console.login committed code (use proper error handling) - Database columns use
snake_case; TypeScript fields usecamelCase - IDs use CUID2 via
@paralleldrive/cuid2
Use GitHub Issues to report bugs or request features. Include steps to reproduce for bugs.
By contributing, you agree that your contributions will be licensed under the same license as the project.