Add db reset command
We should have a db reset command that does drop then create then prepare (maybe can avoid the 'create' since prepare can do that too)
Original:
It'd be nice to able to do:
HANAMI_ENV=test hanami db drop create prepareInstead, now this only drops the DB and ignores the other args.
This is an interesting idea! But I'd also be worried about leading to misunderstandings about how the rest of the CLI commands work (where we would support no such chaining).
My preference would be to double down on something like "db prepare" and make sure it's truly a one-stop command to go from zero to fully ready database.
And then if someone wants to chain it with db drop, they can use seperate &&-combined shell commands. After all, this is what the shell is there for!
Perhaps your desire to do a single-operation drop->create->prepare is motivation for us to create a single db reset command that does all that together? (and which will only ever work in dev/test environments only).
Yea that's fair! db reset seems like the best solution. Changing the title of this issue