Add a database migration
SupaCloud uses sequential, numbered SQL migrations in server/migrations/.
-
Find the next number — safely. Migration numbers are a shared namespace across parallel developers and worktrees. Before picking a number:
Terminal window git fetchls server/migrations/ # scan the highest number on mainAlso scan any sibling worktrees. Then take the next free number.
-
Add the file as
NNN_short_description.sqlinserver/migrations/. -
Verify it applies and the server still type-checks:
Terminal window cd server && cargo check