@azure/avocado
Advanced tools
Comparing version 0.2.0 to 0.2.1
@@ -14,2 +14,4 @@ "use strict"; | ||
const yaml = tslib_1.__importStar(require("js-yaml")); | ||
const consoleRed = "\x1b[31m"; | ||
const consoleReset = "\x1b[0m"; | ||
/** | ||
@@ -28,2 +30,3 @@ * The function executes the given `tool` and prints errors to `stderr`. | ||
for await (const e of errors) { | ||
report.error(`${consoleRed}error: ${consoleReset}`); | ||
report.error(yaml.safeDump(e)); | ||
@@ -36,3 +39,3 @@ ++errorsNumber; | ||
catch (e) { | ||
report.error("INTERNAL ERROR"); | ||
report.error(`${consoleRed}INTERNAL ERROR${consoleReset}`); | ||
report.error(e); | ||
@@ -39,0 +42,0 @@ return 1; |
{ | ||
"name": "@azure/avocado", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "A validator of OpenAPI configurations", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -18,2 +18,5 @@ import * as path from "path" | ||
const consoleRed = "\x1b[31m" | ||
const consoleReset = "\x1b[0m" | ||
/** | ||
@@ -34,2 +37,3 @@ * The function executes the given `tool` and prints errors to `stderr`. | ||
for await (const e of errors) { | ||
report.error(`${consoleRed}error: ${consoleReset}`) | ||
report.error(yaml.safeDump(e)) | ||
@@ -41,3 +45,3 @@ ++errorsNumber | ||
} catch (e) { | ||
report.error("INTERNAL ERROR") | ||
report.error(`${consoleRed}INTERNAL ERROR${consoleReset}`) | ||
report.error(e) | ||
@@ -44,0 +48,0 @@ return 1 |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
26741
417