markdownlint-cli2
Advanced tools
Comparing version 0.1.1 to 0.1.2
@@ -22,6 +22,7 @@ #!/usr/bin/env node | ||
const mergeOptions = require("./merge-options"); | ||
const resolveAndRequire = require("./resolve-and-require"); | ||
// Variables | ||
const packageName = "markdownlint-cli2"; | ||
const packageVersion = "0.1.1"; | ||
const packageVersion = "0.1.2"; | ||
const libraryName = "markdownlint"; | ||
@@ -61,5 +62,3 @@ const libraryVersion = markdownlintLibrary.getVersion(); | ||
if (typeof id === "string") { | ||
const paths = [ dir, ...dynamicRequire.resolve.paths("") ]; | ||
const resolved = dynamicRequire.resolve(id, { paths }); | ||
return dynamicRequire(resolved); | ||
return resolveAndRequire(dynamicRequire, id, dir); | ||
} | ||
@@ -66,0 +65,0 @@ return id; |
{ | ||
"name": "markdownlint-cli2", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"description": "A fast, flexible, configuration-based command-line interface for linting Markdown/CommonMark files with the `markdownlint` library", | ||
@@ -25,3 +25,3 @@ "author": { | ||
"lint-watch": "git ls-files | entr npm run lint", | ||
"test": "ava test/append-to-array-test.js test/markdownlint-cli2-test.js test/markdownlint-cli2-test-exec.js test/markdownlint-cli2-test-main.js test/merge-options-test.js", | ||
"test": "ava test/append-to-array-test.js test/markdownlint-cli2-test.js test/markdownlint-cli2-test-exec.js test/markdownlint-cli2-test-main.js test/merge-options-test.js test/resolve-and-require-test.js", | ||
"test-cover": "c8 --check-coverage --branches 100 --functions 100 --lines 100 --statements 100 npm test", | ||
@@ -37,3 +37,4 @@ "test-watch": "git ls-files | entr npm run test" | ||
"markdownlint-cli2-fix.js", | ||
"merge-options.js" | ||
"merge-options.js", | ||
"resolve-and-require.js" | ||
], | ||
@@ -40,0 +41,0 @@ "dependencies": { |
@@ -277,3 +277,3 @@ # markdownlint-cli2 | ||
- repo: https://github.com/DavidAnson/markdownlint-cli2 | ||
rev: v0.1.1 | ||
rev: v0.1.2 | ||
hooks: | ||
@@ -304,2 +304,3 @@ - id: markdownlint-cli2 | ||
- 0.1.1 - Restore previous use of `require` | ||
- 0.1.2 - Update use of `require` to be more flexible | ||
@@ -306,0 +307,0 @@ <!-- markdownlint-disable line-length --> |
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
42254
8
683
350