Scripts & tooling
Use bun run <command> rather than calling scripts directly. The tables below are auto-generated from each app’s scripts/README.md and package.json, updated when you add a command and run the boringstack docs generator.
apps/ui
Section titled “apps/ui”Folder
Purpose
[ci/](ci/)Pre-push gate, CI manifest
[dev/](dev/)Local developer workflow guards
[codegen/](codegen/)Scaffolding and OpenAPI contract generation
[quality/](quality/)Test and bundle adjunct checks outside ESLint
[lint-meta/](lint-meta/)Static meta-lint rules ([RULES.md](lint-meta/RULES.md))
Command
Script
Purpose
bun run devdev/preflight-host-dev.shRefuses to run `bun run dev` on the host when the `ui-dev` compose container is already up.
bun run size:check:modulepreloadquality/check-modulepreload-size-coverage.tsAfter `bun run build`, every `<link rel="modulepreload">` in dist/index.html must match at least one glob in `.size-limit.json`.
bun run lint:metalint-meta/cli.tsStatic checks for files ESLint can't parse as JavaScript.
bun run lint:meta:verifylint-meta/cli.tsStatic checks for files ESLint can't parse as JavaScript.
bun run generate:lint-meta-docslint-meta/generate-rules-md.tstsx scripts/lint-meta/generate-rules-md.ts
bun run check:lint-meta-docslint-meta/generate-rules-md.tstsx scripts/lint-meta/generate-rules-md.ts --check
bun run check:scripts-docscheck-scripts-docs.tstsx scripts/check-scripts-docs.ts
bun run test:ciquality/run-tests-clean.tsRuns vitest and fails when the suite prints warning noise to stdout/stderr.
bun run new:componentcodegen/new-component.tsScaffold a new component folder with the 8-file anatomy.
bun run new:featurecodegen/new-feature.tsScaffold a new feature folder.
bun run generate:apicodegen/generate-api.tsRegenerate src/lib/api/schema.d.ts from the API app's OpenAPI document.
bun run generate:api:checkcodegen/generate-api.tsRegenerate src/lib/api/schema.d.ts from the API app's OpenAPI document.
bun run pre-pushci/pre-push.shLocal mirror of the UI app's CI gate.
- 1/${TOTAL} Fast checks (lint, lint:meta, format, typecheck, knip)
- 2/${TOTAL} Dependency vulnerability scan
- 3/${TOTAL} Tests
- 4/${TOTAL} Production build
- 5/${TOTAL} Bundle size budgets
- 6/${TOTAL} OpenAPI schema drift
apps/api
Section titled “apps/api”Folder
Purpose
[ci/](ci/)Pre-push gate, CI manifest
[dev/](dev/)Local developer workflow guards
[codegen/](codegen/)Scaffolding, ACL type sync, VAPID key generation
[db/](db/)Database seed utilities
[loadtest/](loadtest/)k6 golden-path load test against the dev stack
[quality/](quality/)Test and coverage adjunct checks outside ESLint
[lint-meta/](lint-meta/)Static meta-lint rules ([RULES.md](lint-meta/RULES.md))
Command
Script
Purpose
bun run testquality/run-tests-clean.tsRuns bun test and fails when the suite prints warning noise to stdout/stderr.
bun run test:coveragequality/check-coverage.tsbun run build:templates && NODE_ENV=test bun run scripts/quality/check-coverage.ts
bun run test:securityquality/run-tests-clean.tsRuns bun test and fails when the suite prints warning noise to stdout/stderr.
bun run check:security-manifestquality/check-security-manifest.tsReconciles `security-spec/findings.json` against a real run of the security spec suite.
bun run write:security-manifestquality/write-security-manifest.tsRegenerates the per-case expectations in `security-spec/findings.json` from an actual run.
bun run devdev/preflight-host-dev.shRefuses to run `bun run dev` on the host when the `api-dev` compose container is already up.
bun run db:seeddb/seed-superuser.tsOptional first-boot superuser bootstrap.
bun run lint:metalint-meta/cli.tsStatic checks for files ESLint can't parse as JavaScript.
bun run lint:meta:verifylint-meta/cli.tsStatic checks for files ESLint can't parse as JavaScript.
bun run generate:lint-meta-docslint-meta/generate-rules-md.tsbun run scripts/lint-meta/generate-rules-md.ts
bun run check:lint-meta-docslint-meta/generate-rules-md.tsbun run scripts/lint-meta/generate-rules-md.ts --check
bun run check:scripts-docscheck-scripts-docs.tsbun run scripts/check-scripts-docs.ts
bun run new:resourcecodegen/new-resource.tsScaffolds a new API resource.
bun run vapid:generatecodegen/vapid-generate.tsGenerate a fresh VAPID keypair for the Web Push notification channel.
bun run new:notification-eventcodegen/new-notification-event.tsScaffolds a new notification event.
bun run new:actioncodegen/new-action.tsbun run scripts/codegen/new-action.ts
bun run new:rolecodegen/new-role.tsbun run scripts/codegen/new-role.ts
bun run new:subjectcodegen/new-subject.tsbun run scripts/codegen/new-subject.ts
bun run new:featurecodegen/new-feature.tsbun run scripts/codegen/new-feature.ts
bun run new:findingcodegen/new-finding.tsScaffolds a security-spec finding.
bun run generate:acl-typescodegen/generate-acl-types.tsCopies the canonical ACL type spine from apps/api to apps/ui so the two workspace apps stay byte-identical on Role / Action / Subject / FeatureKey unions.
bun run generate:acl-types:checkcodegen/generate-acl-types.tsCopies the canonical ACL type spine from apps/api to apps/ui so the two workspace apps stay byte-identical on Role / Action / Subject / FeatureKey unions.
bun run pre-pushci/pre-push.shLocal mirror of apps/api CI gate.
bun run loadtestloadtest/run.shRun the golden-path k6 load test against the local dev stack.
- 1/${TOTAL} Fast checks (typecheck, lint, lint:meta, knip)
- 2/${TOTAL} Dependency vulnerability scan
- 3/${TOTAL} Ensure Postgres + Valkey are running and migrated
- 4/${TOTAL} Test suite (integration)
- 5/${TOTAL} Test coverage
- 6/${TOTAL} Production build
- 7/${TOTAL} OpenAPI schema drift
- 8/${TOTAL} ACL types drift
Related
Section titled “Related”- Commands cheatsheet, infra flags and day-to-day workflow
- lint:meta rules, structural checks under
scripts/lint-meta/ - Lint as the contract, ESLint merge gate