db-migrate / db-migrate/node-db-migrate
Add init optionality
- Dominant language
- JavaScript
- Stars
- 2.3k
- Forks
- 361
- PR merge metrics
- No merged PRs in 30d
Description
# Current behavior
If db-migrate tries to connect to a database that does not yet exists it is going to throw an error. The user needs to create the database with fitting permissions first.
# Proposed solution
Add a command line option `--init` which tells db-migrate to first check if the database exists and then tries to execute a database execution. This tasks has items listed below.
# Affected drivers
All: New method `showDatabases` is needed
Items:
- https://github.com/db-migrate/pg/issues/6
- https://github.com/db-migrate/mysql/issues/2
- https://github.com/db-migrate/db-migrate-base/issues/2
# API extensions
- New command line option
##
---
Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/29956524-add-init-optionality?utm_campaign=plugin&utm_content=tracker%2F73887&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F73887&utm_medium=issues&utm_source=github).
Contributor guide
Assessment
This issue has not been assessed yet.