#!/bin/bash

OUTPUT_DIR="src/entity"
rm -rf $OUTPUT_DIR

PG_USER="dipper"
PG_PWD="dipper"
PG_DB="dipper"

DATABASE_URL="postgresql://$PG_USER:$PG_PWD@127.0.0.1:5432/$PG_DB"
sea-orm-cli generate entity --model-extra-derives='salvo::prelude::ToSchema' --database-url=$DATABASE_URL --database-schema=public --max-connections=10 --with-serde=both -o $OUTPUT_DIR
