(schema = getPaths().api.dbSchema)
| 7 | import { runCommandTask, getPaths } from '../lib' |
| 8 | |
| 9 | const skipTask = (schema = getPaths().api.dbSchema) => { |
| 10 | if (!fs.existsSync(schema)) { |
| 11 | console.log( |
| 12 | `Skipping database and Prisma client generation, no \`schema.prisma\` file found: \`${schema}\``, |
| 13 | ) |
| 14 | return true |
| 15 | } |
| 16 | return false |
| 17 | } |
| 18 | |
| 19 | export const generatePrismaCommand = (schema) => { |
| 20 | if (skipTask(schema)) { |
no test coverage detected