M0: foundation — monorepo, PostGIS schema, deck query, app shell

Greenfield scaffold for Linkder, a swipe-to-hire marketplace for local
professional services.

- pnpm/turbo monorepo: apps/web, packages/{shared,db}
- Postgres 16 + PostGIS via docker compose (ports 5442/6389 to avoid
  clashing with other local stacks)
- Drizzle schema, 23 tables, geography(Point,4326) with GiST indexes
- Domain core in packages/shared: integer-cent money, status transition
  graphs, deck ranking weights, cancellation policy — 46 unit tests
- Deck query: filtering in Postgres on the GiST index, ranking in JS so
  the weights stay tunable — 18 integration tests against a seeded DB
- Deterministic seed placing pros at known distances, including three
  that must NOT appear on a deck (out of radius, unverified, away)
- Next.js 15 app shell with a working swipe deck
- CI: typecheck, lint, test, build against live postgres+redis

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
serfowi
2026-08-20 13:32:35 -04:00
co-authored by Claude Opus 5
commit 19623bcccb
66 changed files with 12412 additions and 0 deletions
+27
View File
@@ -0,0 +1,27 @@
{
"name": "linkder",
"private": true,
"packageManager": "pnpm@9.15.4",
"engines": { "node": ">=20" },
"scripts": {
"dev": "turbo run dev",
"build": "turbo run build",
"lint": "turbo run lint",
"typecheck": "turbo run typecheck",
"test": "turbo run test",
"test:e2e": "turbo run test:e2e",
"format": "prettier --write \"**/*.{ts,tsx,md,json}\"",
"db:generate": "pnpm --filter @linkder/db generate",
"db:migrate": "pnpm --filter @linkder/db migrate",
"db:seed": "pnpm --filter @linkder/db seed",
"db:studio": "pnpm --filter @linkder/db studio",
"services:up": "docker compose up -d postgres redis",
"services:down": "docker compose down"
},
"devDependencies": {
"@types/node": "^22.10.5",
"prettier": "^3.4.2",
"turbo": "^2.3.3",
"typescript": "^5.7.3"
}
}