()
| 2 | import Knex from 'knex'; |
| 3 | |
| 4 | export const getConfig = async () => { |
| 5 | const config = await loadConfig({ |
| 6 | extensions: [() => ({ name: 'dbmigrations' })], |
| 7 | }); |
| 8 | if (!config) { |
| 9 | throw new Error('Missing dbmigrations config'); |
| 10 | } |
| 11 | const conf = await config.getDefault().extension('dbmigrations'); |
| 12 | |
| 13 | return conf; |
| 14 | }; |
| 15 | |
| 16 | /** |
| 17 | * Creates knex based database using migration configuration |
no outgoing calls
no test coverage detected
searching dependent graphs…