Add db/create db/drop console commands #15871
Unanswered
leevigraham
asked this question in
Ideas
Replies: 1 comment 2 replies
-
You already have those. And install |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
It would be handy to have
db/create
anddb/drop
console commands added to Craft CMS.Motivation:
We (Newism) create feature previews based on branches in our testing / CI environment. This involves creating new databases during the setup process and deleting the site / database when the branch is merged / deleted.
I'm currently doing this with my own hand rolled console command in a custom module. I like the approach of using the craft console because they .env variables are already loaded.
This could further be improved using the DB driver classes and the loaded DB config.
Symfony has these commands… I'm sure Laravel would have them as well.
Beta Was this translation helpful? Give feedback.
All reactions