| name | create-migration |
| description | Scaffold a new timestamped Supabase migration file in supabase/migrations/ |
| disable-model-invocation | true |
Create Migration
Scaffold a new Supabase migration file with a timestamped filename and boilerplate template.
Arguments
A short snake_case migration name (e.g., add_waitlist_table, create_notifications).
Steps
- Generate a timestamp in
YYYYMMDDHHMMSS format using the current UTC time
- Create the migration file at
supabase/migrations/<timestamp>_<name>.sql
- Populate with the template below
- Open the file for editing
Template
After Creating
Report the file path and remind the user to:
- Write the migration SQL
- Run
supabase db diff to validate
- Run
supabase db reset to apply locally and verify