DOCS / GETTING STARTED
Commands
Development runs through the just recipes in the root justfile, some
of which call npm scripts in web/. Run just on its own to list every
recipe in order. Recipes load .env automatically (set dotenv-load), and the database recipes default
DATABASE_URL to postgres://postgres:postgres@localhost:5433/saas when
it isn't set.
Getting started
| Command | What it does |
|---|---|
just |
Lists every recipe (just --list --unsorted). |
just setup |
Fresh clone to running app: creates .env from .env.example (never overwrites), starts Postgres, applies migrations, runs npm install in web/. |
just dev |
Runs the API and the SPA together; ctrl-c stops both. |
just api |
The API alone: cargo run in api/, serving http://localhost:8787. |
just web |
The SPA alone: npm run dev in web/, serving http://localhost:5173. |
Database
| Command | What it does |
|---|---|
just db-up |
Starts the db service from docker-compose.yml and waits until it's healthy. |
just db-down |
Stops the database container (data is kept in the db-data volume). |
just db-reset |
Destroys all local data: asks for confirmation, then docker compose down -v, db-up, and migrate-run. |
just psql |
Opens a psql shell on the development database. |
just migration <name> |
Creates a new migration with sqlx migrate add --timestamp, named like 20261120143000_add-widgets.sql. The 4-digit numbers belong to the kit's own migrations (Pulling kit updates). Example: just migration add-widgets. |
just migrate-run |
Applies pending migrations. |
just prepare |
Regenerates the offline query cache (api/.sqlx/). Run it after changing any SQL or migration, and commit the result. |
[ full guide ]
The rest of this guide comes with the repo.
- Quality
- Code generation
- Deployment
- Frontend scripts