Skip to content

Commit

Permalink
tools: update lint-md-dependencies to [email protected]
Browse files Browse the repository at this point in the history
PR-URL: #47045
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Moshe Atlow <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Yagiz Nizipli <[email protected]>
  • Loading branch information
nodejs-github-bot authored and targos committed Mar 18, 2023
1 parent d1ca5b6 commit 8850dac
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
8 changes: 4 additions & 4 deletions tools/lint-md/lint-md.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11966,20 +11966,20 @@ function parseParameters(value) {
const parameters = {};
return value
.replace(
/\s+([-\w]+)(?:=(?:"((?:\\[\s\S]|[^"])+)"|'((?:\\[\s\S]|[^'])+)'|((?:\\[\s\S]|[^"'\s])+)))?/gi,
/\s+([-\w]+)(?:=(?:"((?:\\[\s\S]|[^"])*)"|'((?:\\[\s\S]|[^'])*)'|((?:\\[\s\S]|[^"'\s])+)))?/gi,
replacer
)
.replace(/\s+/g, '')
? null
: parameters
function replacer(_, $1, $2, $3, $4) {
let value = $2 || $3 || $4 || '';
let value = $2 === undefined ? ($3 === undefined ? $4 : $3) : $2;
const number = Number(value);
if (value === 'true' || value === '') {
if (value === 'true' || value === undefined) {
value = true;
} else if (value === 'false') {
value = false;
} else if (!Number.isNaN(number)) {
} else if (value.trim() && !Number.isNaN(number)) {
value = number;
}
parameters[$1] = value;
Expand Down
14 changes: 7 additions & 7 deletions tools/lint-md/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tools/lint-md/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"devDependencies": {
"@rollup/plugin-commonjs": "^24.0.1",
"@rollup/plugin-node-resolve": "^15.0.1",
"rollup": "^3.18.0",
"rollup": "^3.19.1",
"rollup-plugin-cleanup": "^3.2.1"
}
}

0 comments on commit 8850dac

Please sign in to comment.