Skip to content

Setup

A checkout uses the Node version in .nvmrc and the scripts in the root package.json.

Node and Docker

SourceValue
.nvmrc26.12.0
package.json engines.node>=26.0.0
.npmrcengine-strict=true, save-exact=true, ignore-scripts=true

npm ci refuses a Node outside that engines range. Install scripts stay off.

npm run check needs Docker. Postgres tests start the pinned image with docker run from tests/support/postgres.ts and fail when the daemon is missing. The image is the postgres entry in deployment/images/bases.lock.json.

Checkout

From the repository root (README.md):

npm ci
git config core.hooksPath scripts/githooks
npm run check

The hooks are opt-in. scripts/githooks/pre-commit runs gitleaks when it is on PATH, then npm run guards. scripts/githooks/commit-msg runs scripts/guards/commit-msg.ts. CI runs the commit check and gitleaks on the pull request either way. What npm run check runs is Checks.

Scripts

Every script in the root package.json:

ScriptCommand
checknpm run typecheck && npm run lint && npm run guards && npm test
typechecktsc -b
lintbiome ci . && depcruise --config scripts/lint/.dependency-cruiser.cjs .
formatbiome format --write .
guardsvitest run scripts/guards
notes:indexnode scripts/guards/notes.ts
testnode scripts/test/run.ts
test:imagesnode scripts/test/run.ts --images
budgetsnode scripts/budgets/check.ts
semgrep:fixturesnode scripts/lint/semgrep-fixtures.ts run
dev:upnode deployment/preflight/stack.ts -- up --env dev --compose deployment/compose.dev.yaml --interpolation-env ../unset-dev-env/dev-public.env
dev:downnode deployment/preflight/stack.ts -- down --env dev --compose deployment/compose.dev.yaml --interpolation-env ../unset-dev-env/dev-public.env
dev:source:upnode deployment/preflight/stack.ts -- up --env dev --source --compose deployment/compose.dev.source.yaml --interpolation-env ../unset-dev-env/dev-public.env
dev:source:downnode deployment/preflight/stack.ts -- down --env dev --source --compose deployment/compose.dev.source.yaml --interpolation-env ../unset-dev-env/dev-public.env
local:upnode deployment/preflight/stack.ts -- up --env local --compose deployment/compose.local.yaml --interpolation-env ../unset-dev-env/dev-public.env
local:downnode deployment/preflight/stack.ts -- down --env local --compose deployment/compose.local.yaml --interpolation-env ../unset-dev-env/dev-public.env

notes:index is on Docs rules. The six stack commands are the Compose wrappers. Their files are on compose. The interpolation env and the secret files sit outside this checkout.