@commitlint/load
Advanced tools
Comparing version 9.1.2 to 10.0.0
@@ -6,2 +6,30 @@ # Change Log | ||
# [10.0.0](https://github.com/conventional-changelog/commitlint/compare/v9.1.2...v10.0.0) (2020-08-16) | ||
### Bug Fixes | ||
* update dependency cosmiconfig to v7 ([#2044](https://github.com/conventional-changelog/commitlint/issues/2044)) ([f4db933](https://github.com/conventional-changelog/commitlint/commit/f4db93324698ea39528be0d2692151546c2b5517)) | ||
* update dependency execa to v4 ([#1936](https://github.com/conventional-changelog/commitlint/issues/1936)) ([8efb441](https://github.com/conventional-changelog/commitlint/commit/8efb44193058d286f7325327a6d33936b273ec91)) | ||
* 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 +36,0 @@ |
@@ -34,3 +34,3 @@ "use strict"; | ||
path: resolvedParserPreset, | ||
parserOpts: require(resolvedParserPreset) | ||
parserOpts: require(resolvedParserPreset), | ||
}; | ||
@@ -42,3 +42,3 @@ } | ||
cwd: base, | ||
parserPreset: config.parserPreset | ||
parserPreset: config.parserPreset, | ||
}); | ||
@@ -66,3 +66,3 @@ const preset = pick_config_1.pickConfig(mergeWith_1.default(extended, config, w)); | ||
if (Array.isArray(config.plugins)) { | ||
config.plugins.forEach(plugin => { | ||
config.plugins.forEach((plugin) => { | ||
if (typeof plugin === 'string') { | ||
@@ -77,3 +77,3 @@ load_plugin_1.default(preset.plugins, plugin, process.env.DEBUG === 'true'); | ||
const rules = preset.rules ? preset.rules : {}; | ||
const qualifiedRules = (await Promise.all(Object.entries(rules || {}).map(entry => execute_rule_1.default(entry)))).reduce((registry, item) => { | ||
const qualifiedRules = (await Promise.all(Object.entries(rules || {}).map((entry) => execute_rule_1.default(entry)))).reduce((registry, item) => { | ||
const [key, value] = item; | ||
@@ -90,3 +90,3 @@ registry[key] = value; | ||
plugins: preset.plugins, | ||
rules: qualifiedRules | ||
rules: qualifiedRules, | ||
}; | ||
@@ -93,0 +93,0 @@ } |
@@ -6,2 +6,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.loadConfig = void 0; | ||
const path_1 = __importDefault(require("path")); | ||
@@ -8,0 +9,0 @@ const cosmiconfig_1 = require("cosmiconfig"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.loadParserOpts = void 0; | ||
async function loadParserOpts(parserName, pendingParser) { | ||
@@ -16,3 +17,3 @@ // Await for the module, loaded with require | ||
parserName.startsWith('conventional-changelog-')) { | ||
return await new Promise(resolve => { | ||
return await new Promise((resolve) => { | ||
const result = parser.parserOpts((_, opts) => { | ||
@@ -24,3 +25,3 @@ resolve(opts.parserOpts); | ||
if (result) { | ||
Promise.resolve(result).then(opts => { | ||
Promise.resolve(result).then((opts) => { | ||
resolve(opts.parserOpts); | ||
@@ -27,0 +28,0 @@ }); |
@@ -16,3 +16,3 @@ "use strict"; | ||
throw new plugin_errors_1.WhitespacePluginError(pluginName, { | ||
pluginName: longName | ||
pluginName: longName, | ||
}); | ||
@@ -35,3 +35,3 @@ } | ||
pluginName: longName, | ||
commitlintPath: path_1.default.resolve(__dirname, '../..') | ||
commitlintPath: path_1.default.resolve(__dirname, '../..'), | ||
}); | ||
@@ -38,0 +38,0 @@ } |
@@ -6,4 +6,5 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.pickConfig = void 0; | ||
const pick_1 = __importDefault(require("lodash/pick")); | ||
exports.pickConfig = (input) => pick_1.default(input, 'extends', 'rules', 'plugins', 'parserPreset', 'formatter', 'ignores', 'defaultIgnores'); | ||
//# sourceMappingURL=pick-config.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.MissingPluginError = exports.WhitespacePluginError = void 0; | ||
class WhitespacePluginError extends Error { | ||
@@ -4,0 +5,0 @@ constructor(pluginName, data = {}) { |
@@ -6,2 +6,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.getNamespaceFromTerm = exports.getShorthandName = exports.normalizePackageName = void 0; | ||
const path_1 = __importDefault(require("path")); | ||
@@ -8,0 +9,0 @@ // largely adapted from eslint's plugin system |
{ | ||
"name": "@commitlint/load", | ||
"version": "9.1.2", | ||
"version": "10.0.0", | ||
"description": "Load shared commitlint configuration", | ||
@@ -15,3 +15,3 @@ "main": "lib/load.js", | ||
"engines": { | ||
"node": ">=v8.17.0" | ||
"node": ">=v10.22.0" | ||
}, | ||
@@ -38,17 +38,17 @@ "repository": { | ||
"devDependencies": { | ||
"@commitlint/test": "^9.1.2", | ||
"@commitlint/utils": "^9.1.2", | ||
"@types/lodash": "4.14.157", | ||
"execa": "^3.4.0" | ||
"@commitlint/test": "^10.0.0", | ||
"@commitlint/utils": "^10.0.0", | ||
"@types/lodash": "4.14.159", | ||
"execa": "^4.0.0" | ||
}, | ||
"dependencies": { | ||
"@commitlint/execute-rule": "^9.1.2", | ||
"@commitlint/resolve-extends": "^9.1.2", | ||
"@commitlint/types": "^9.1.2", | ||
"@commitlint/execute-rule": "^10.0.0", | ||
"@commitlint/resolve-extends": "^10.0.0", | ||
"@commitlint/types": "^10.0.0", | ||
"chalk": "4.1.0", | ||
"cosmiconfig": "^6.0.0", | ||
"cosmiconfig": "^7.0.0", | ||
"lodash": "^4.17.19", | ||
"resolve-from": "^5.0.0" | ||
}, | ||
"gitHead": "41d4f5851508be1421bd23e0424cacf043bc6a88" | ||
"gitHead": "3982e5a6bf0c28e4b1109e8516d7fdcfad411eac" | ||
} |
@@ -16,3 +16,3 @@ > Load shared commitlint configuration | ||
load({extends: ['./package']}).then(config => console.log(config)); | ||
load({extends: ['./package']}).then((config) => console.log(config)); | ||
// => { extends: ['./package', './package-b'], rules: {} } | ||
@@ -19,0 +19,0 @@ ``` |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
39422
370
+ Added@commitlint/execute-rule@10.0.0(transitive)
+ Added@commitlint/resolve-extends@10.0.0(transitive)
+ Added@commitlint/types@10.0.0(transitive)
+ Addedcosmiconfig@7.1.0(transitive)
- Removed@commitlint/execute-rule@9.1.2(transitive)
- Removed@commitlint/resolve-extends@9.1.2(transitive)
- Removed@commitlint/types@9.1.2(transitive)
- Removedcosmiconfig@6.0.0(transitive)
Updated@commitlint/types@^10.0.0
Updatedcosmiconfig@^7.0.0