Always log output in `showResults()`
Closed this issue · 3 comments
elmeister commented
Thank you for the helpful tool
Do you mind to change the output f the showResults()
function to something like the following snippet, so we'll be able to track errors and passed migrations in build output please?
function showResults({ error, results }: MigrationResultSet) {
if (results) {
for (const it of results) {
console.log(`> ${it.status}: ${it.migrationName} (${it.direction})`)
}
}
if (error) {
console.error(error)
process.exit(1)
}
}
acro5piano commented
@elmeister Thanks for the suggestion. Yes, please create a pull request! The change would be helpful.
elmeister commented
PR created, thank you, and once again - ❤️ for the project you made
acro5piano commented
Released on v0.2.1. Thanks @elmeister
https://github.com/acro5piano/kysely-migration-cli/releases/tag/v0.2.1