@commitlint/format
Advanced tools
Comparing version 9.1.2 to 10.0.0
@@ -6,2 +6,24 @@ # Change Log | ||
# [10.0.0](https://github.com/conventional-changelog/commitlint/compare/v9.1.2...v10.0.0) (2020-08-16) | ||
* refactor!: drop support for node 8 (#1999) ([751f39f](https://github.com/conventional-changelog/commitlint/commit/751f39f284ef232574a176c3c11b1982ee544166)), closes [#1999](https://github.com/conventional-changelog/commitlint/issues/1999) | ||
### BREAKING CHANGES | ||
* remove node 8 from circle-ci checks | ||
also remove node 13 because we do not support experimental versions | ||
* docs: update node v10 to latest LTS 10 version | ||
Co-authored-by: Cedric van Putten <me@bycedric.com> | ||
Co-authored-by: Cedric van Putten <me@bycedric.com> | ||
## [9.1.2](https://github.com/conventional-changelog/commitlint/compare/v9.1.1...v9.1.2) (2020-07-13) | ||
@@ -8,0 +30,0 @@ |
@@ -6,2 +6,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.formatResult = exports.format = void 0; | ||
const chalk_1 = __importDefault(require("chalk")); | ||
@@ -15,4 +16,4 @@ const DEFAULT_SIGNS = [' ', '⚠', '✖']; | ||
return results | ||
.filter(r => Array.isArray(r.warnings) || Array.isArray(r.errors)) | ||
.map(result => [...fi(result), ...fr(result)]) | ||
.filter((r) => Array.isArray(r.warnings) || Array.isArray(r.errors)) | ||
.map((result) => [...fi(result), ...fr(result)]) | ||
.reduce((acc, item) => (Array.isArray(item) ? [...acc, ...item] : [...acc, item]), []) | ||
@@ -38,5 +39,5 @@ .join('\n'); | ||
function formatResult(result = {}, options = {}) { | ||
const { signs = DEFAULT_SIGNS, colors = DEFAULT_COLORS, color: enabled = true } = options; | ||
const { signs = DEFAULT_SIGNS, colors = DEFAULT_COLORS, color: enabled = true, } = options; | ||
const { errors = [], warnings = [] } = result; | ||
const problems = [...errors, ...warnings].map(problem => { | ||
const problems = [...errors, ...warnings].map((problem) => { | ||
const sign = signs[problem.level] || ''; | ||
@@ -66,3 +67,3 @@ const color = colors[problem.level] || 'white'; | ||
help, | ||
help ? '' : undefined | ||
help ? '' : undefined, | ||
].filter((line) => typeof line === 'string'); | ||
@@ -69,0 +70,0 @@ } |
"use strict"; | ||
function __export(m) { | ||
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p]; | ||
} | ||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); | ||
}) : (function(o, m, k, k2) { | ||
if (k2 === undefined) k2 = k; | ||
o[k2] = m[k]; | ||
})); | ||
var __exportStar = (this && this.__exportStar) || function(m, exports) { | ||
for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p); | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var format_1 = require("./format"); | ||
exports.default = format_1.default; | ||
__export(require("./format")); | ||
Object.defineProperty(exports, "default", { enumerable: true, get: function () { return format_1.default; } }); | ||
__exportStar(require("./format"), exports); | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@commitlint/format", | ||
"version": "9.1.2", | ||
"version": "10.0.0", | ||
"description": "Format commitlint reports", | ||
@@ -15,3 +15,3 @@ "main": "lib/index.js", | ||
"engines": { | ||
"node": ">=v8.17.0" | ||
"node": ">=v10.22.0" | ||
}, | ||
@@ -38,9 +38,9 @@ "repository": { | ||
"devDependencies": { | ||
"@commitlint/utils": "^9.1.2" | ||
"@commitlint/utils": "^10.0.0" | ||
}, | ||
"dependencies": { | ||
"@commitlint/types": "^9.1.2", | ||
"@commitlint/types": "^10.0.0", | ||
"chalk": "^4.0.0" | ||
}, | ||
"gitHead": "41d4f5851508be1421bd23e0424cacf043bc6a88" | ||
"gitHead": "3982e5a6bf0c28e4b1109e8516d7fdcfad411eac" | ||
} |
@@ -30,4 +30,4 @@ > Format commitlint reports | ||
name: 'some-error', | ||
message: 'This will show up red as it has level 2' | ||
} | ||
message: 'This will show up red as it has level 2', | ||
}, | ||
], | ||
@@ -39,3 +39,3 @@ warnings: [ | ||
name: 'some-hint', | ||
message: 'This will not show up as it has level 0' | ||
message: 'This will not show up as it has level 0', | ||
}, | ||
@@ -46,10 +46,10 @@ { | ||
name: 'some-warning', | ||
message: 'This will show up yellow as it has level 1' | ||
} | ||
] | ||
} | ||
] | ||
message: 'This will show up yellow as it has level 1', | ||
}, | ||
], | ||
}, | ||
], | ||
}, | ||
{ | ||
color: false | ||
color: false, | ||
} | ||
@@ -56,0 +56,0 @@ ); |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
18683
101
+ Added@commitlint/types@10.0.0(transitive)
- Removed@commitlint/types@9.1.2(transitive)
Updated@commitlint/types@^10.0.0