(err?: string | Error)
| 16 | } |
| 17 | |
| 18 | static die(err?: string | Error) { |
| 19 | if (err) { |
| 20 | if (err instanceof Error && err.name === 'ExitPromptError') { |
| 21 | // prompt exit error, just log and exit gracefully |
| 22 | Utils.goodbye(); |
| 23 | } else { |
| 24 | prompt.log.error('!! ' + (_verbose && (err as Error).stack ? (err as Error).stack : err.toString())); |
| 25 | } |
| 26 | process.exit(1); |
| 27 | } |
| 28 | } |
| 29 | |
| 30 | static goodbye() { |
| 31 | const funMessages = [ |
no test coverage detected