(msg?: string)
| 17 | |
| 18 | /** Write an error message to stderr (if given) and exit with code 1. */ |
| 19 | export function cliError(msg?: string): never { |
| 20 | if (msg) console.error(msg) |
| 21 | process.exit(1) |
| 22 | return undefined as never |
| 23 | } |
| 24 | |
| 25 | /** Write a message to stdout (if given) and exit with code 0. */ |
| 26 | export function cliOk(msg?: string): never { |
no test coverage detected