error(info) {
    info = typeof info === 'object' ? info : { error: info };
    let { pos, error = '', msg = '' } = info;
    pos = pos ? `${pos} ` : '';
    error = Utils.getErrStack(error);

    const str = `${PRE} ${pos}${msg}${error}`;
    console.error(colors.red(str));
    this.hooks['error'] && this.hooks['error'](str);
  }
Print error message to the command line
@public