`dbmate` package was starting to get a bit polluted. This PR migrates each driver into a separate package, with clean separation between each.
In addition:
* Drivers are now initialized with a URL, avoiding the need to pass `*url.URL` to every method
* Sqlite supports a cleaner syntax for relative paths
* Driver tests now load their test URL from environment variables
Public API of `dbmate` package has not changed (no changes to `main` package).
Supported via `--migrations-table` CLI flag or `DBMATE_MIGRATIONS_TABLE` environment variable.
Specified table name is quoted when necessary.
For PostgreSQL specifically, it's also possible to specify a custom schema (for example: `--migrations-table=foo.migrations`).
Closes#168
* adding verbose output for statement execution
* fixing lint and redefined v flag
* changing name due to inherited verbose flag and updating README
* linting
* moving verbose flag to subcommand, removing driver verbose, adding tests
* fixing README, cleaning up spacing
Extending the `dbmate status` command with the ability to set an exit code or quiet output, for use in scripts.
Flag names were copied from `git diff` command.
✨ When using dbmate as a container, since the base image is distroless, we can't do `dbmate up && dbmate wait`, which makes config a bit more cumbersome (e.g. in kubernetes an extra initContainer).
Closes#111Closes#112