handleOutput = (command, result, ctx, isError = false) => {
  if (result.output) {
    const outputTitle = isError ? chalk.redBright(`${error} ${command}:`) : `${info} ${command}:`
    const output = [...(ctx.quiet ? [] : ['', outputTitle]), result.output]
    ctx.output.push(output.join('\n'))
  } else if (isError) {
    // Show generic error when task had no output
    const tag = getTag(result)
    const message = chalk.redBright(`\n${error} ${command} failed without output (${tag}).`)
    if (!ctx.quiet) ctx.output.push(message)
  }
}
Handle task console output.

@param {string} command
@param {import('nano-spawn').Result | import('nano-spawn').SubprocessError} result
@param {Object} ctx
@returns {Error}