Skip to content

Commit

Permalink
chore: correctly use .markdownlintignore in Makefile (#16060)
Browse files Browse the repository at this point in the history
  • Loading branch information
bmish committed Jun 27, 2022
1 parent ae4b449 commit 6840940
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Makefile.js
Expand Up @@ -22,6 +22,7 @@ const checker = require("npm-license"),
ejs = require("ejs"),
loadPerf = require("load-perf"),
yaml = require("js-yaml"),
ignore = require("ignore"),
{ CLIEngine } = require("./lib/cli-engine"),
builtinRules = require("./lib/rules/index");

Expand Down Expand Up @@ -72,8 +73,8 @@ const NODE = "node ", // intentional extra space
// Files
RULE_FILES = glob.sync("lib/rules/*.js").filter(filePath => path.basename(filePath) !== "index.js"),
JSON_FILES = find("conf/").filter(fileType("json")),
MARKDOWNLINT_IGNORED_FILES = fs.readFileSync(path.join(__dirname, ".markdownlintignore"), "utf-8").split("\n"),
MARKDOWN_FILES_ARRAY = find("docs/").concat(ls(".")).filter(fileType("md")).filter(file => !MARKDOWNLINT_IGNORED_FILES.includes(file)),
MARKDOWNLINT_IGNORE_INSTANCE = ignore().add(fs.readFileSync(path.join(__dirname, ".markdownlintignore"), "utf-8")),
MARKDOWN_FILES_ARRAY = MARKDOWNLINT_IGNORE_INSTANCE.filter(find("docs/").concat(ls(".")).filter(fileType("md"))),
TEST_FILES = "\"tests/{bin,conf,lib,tools}/**/*.js\"",
PERF_ESLINTRC = path.join(PERF_TMP_DIR, "eslintrc.yml"),
PERF_MULTIFILES_TARGET_DIR = path.join(PERF_TMP_DIR, "eslint"),
Expand Down

0 comments on commit 6840940

Please sign in to comment.