- Install krab
https://ohkrab.dev/docs/get_started/installation/
- Spin up test database and db browser
docker-compose up
Browser can be accessed at: http://localhost:5556/
- Export database url
export DATABASE_URL=postgres://krab:secret@localhost:5555/krab?sslmode=disable
- Export dir with example
export KRAB_DIR=migrations-simple/
- Run a command
krab
- Try other commands
krab migrate up animals
krab migrate status animals
krab migrate down animals -version v1
krab migrate status animals