Skip to content

Commit 0080350

Browse files
Trottaddaleax
authored andcommitted
tools: update markdown linter
Update remark-preset-lint-node to 1.4.0. This adds `End-Of-Life` as a prohibited string, favoring `End-of-Life` for consistency. Refs: #26251 PR-URL: #26281 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
1 parent ff57a1c commit 0080350

File tree

3 files changed

+100
-80
lines changed

3 files changed

+100
-80
lines changed

tools/lint-md.js

+34-33
Original file line numberDiff line numberDiff line change
@@ -35184,13 +35184,13 @@ function tableCell(node) {
3518435184
/* 302 */
3518535185
/***/ (function(module) {
3518635186

35187-
module.exports = {"name":"remark","version":"10.0.0","description":"Markdown processor powered by plugins","license":"MIT","keywords":["markdown","abstract","syntax","tree","ast","parse","stringify","process"],"homepage":"http://remark.js.org","repository":"https://github.com/remarkjs/remark/tree/master/packages/remark","bugs":"https://github.com/remarkjs/remark/issues","author":"Titus Wormer <[email protected]> (http://wooorm.com)","contributors":["Titus Wormer <[email protected]> (http://wooorm.com)"],"files":["index.js"],"dependencies":{"remark-parse":"^6.0.0","remark-stringify":"^6.0.0","unified":"^7.0.0"},"devDependencies":{"tape":"^4.9.1"},"scripts":{"test":"tape test.js"},"xo":false,"_resolved":"https://registry.npmjs.org/remark/-/remark-10.0.0.tgz","_integrity":"sha512-0fZvVmd9CgDi1qHGsRTyhpJShw60r3/4OSdRpAx+I7CmE8/Jmt829T9KWHpw2Ygw3chRZ26sMorqb8aIolU9tQ==","_from":"[email protected]"};
35187+
module.exports = {"_args":[["[email protected]","/Users/trott/io.js/tools/node-lint-md-cli-rollup"]],"_from":"[email protected]","_id":"[email protected]","_inBundle":false,"_integrity":"sha512-0fZvVmd9CgDi1qHGsRTyhpJShw60r3/4OSdRpAx+I7CmE8/Jmt829T9KWHpw2Ygw3chRZ26sMorqb8aIolU9tQ==","_location":"/remark","_phantomChildren":{},"_requested":{"type":"version","registry":true,"raw":"[email protected]","name":"remark","escapedName":"remark","rawSpec":"10.0.0","saveSpec":null,"fetchSpec":"10.0.0"},"_requiredBy":["/"],"_resolved":"https://registry.npmjs.org/remark/-/remark-10.0.0.tgz","_spec":"10.0.0","_where":"/Users/trott/io.js/tools/node-lint-md-cli-rollup","author":{"name":"Titus Wormer","email":"[email protected]","url":"http://wooorm.com"},"bugs":{"url":"https://github.com/remarkjs/remark/issues"},"contributors":[{"name":"Titus Wormer","email":"[email protected]","url":"http://wooorm.com"}],"dependencies":{"remark-parse":"^6.0.0","remark-stringify":"^6.0.0","unified":"^7.0.0"},"description":"Markdown processor powered by plugins","devDependencies":{"tape":"^4.9.1"},"files":["index.js"],"homepage":"http://remark.js.org","keywords":["markdown","abstract","syntax","tree","ast","parse","stringify","process"],"license":"MIT","name":"remark","repository":{"type":"git","url":"https://github.com/remarkjs/remark/tree/master/packages/remark"},"scripts":{"test":"tape test.js"},"version":"10.0.0","xo":false};
3518835188

3518935189
/***/ }),
3519035190
/* 303 */
3519135191
/***/ (function(module) {
3519235192

35193-
module.exports = {"name":"node-lint-md-cli-rollup","description":"remark packaged for node markdown linting","version":"1.0.0","devDependencies":{"@zeit/ncc":"^0.2.0"},"dependencies":{"markdown-extensions":"^1.1.0","remark":"^10.0.0","remark-lint":"^6.0.3","remark-preset-lint-node":"^1.3.1","unified-args":"^6.0.0","unified-engine":"^5.1.0"},"main":"src/cli-entry.js","scripts":{"build":"ncc build","build-node":"npm run build && cp dist/index.js ../lint-md.js"}};
35193+
module.exports = {"name":"node-lint-md-cli-rollup","description":"remark packaged for node markdown linting","version":"1.0.0","devDependencies":{"@zeit/ncc":"^0.2.0"},"dependencies":{"markdown-extensions":"^1.1.0","remark":"^10.0.0","remark-lint":"^6.0.3","remark-preset-lint-node":"^1.4.0","unified-args":"^6.0.0","unified-engine":"^5.1.0"},"main":"src/cli-entry.js","scripts":{"build":"ncc build","build-node":"npm run build && cp dist/index.js ../lint-md.js"}};
3519435194

3519535195
/***/ }),
3519635196
/* 304 */
@@ -35210,10 +35210,7 @@ module.exports.plugins = [
3521035210
__webpack_require__(316),
3521135211
__webpack_require__(93),
3521235212
__webpack_require__(93),
35213-
[
35214-
__webpack_require__(317),
35215-
'space'
35216-
],
35213+
[__webpack_require__(317), "space"],
3521735214
__webpack_require__(320),
3521835215
__webpack_require__(321),
3521935216
__webpack_require__(322),
@@ -35237,25 +35234,27 @@ module.exports.plugins = [
3523735234
[
3523835235
__webpack_require__(340),
3523935236
{
35240-
'checked': 'x', 'unchecked': ' '
35237+
checked: "x",
35238+
unchecked: " "
3524135239
}
3524235240
],
35243-
[__webpack_require__(341), 'fenced'],
35244-
[__webpack_require__(342), '`'],
35245-
[__webpack_require__(343), 'md'],
35241+
[__webpack_require__(341), "fenced"],
35242+
[__webpack_require__(342), "`"],
35243+
[__webpack_require__(343), "md"],
3524635244
[__webpack_require__(344), 1],
35247-
[__webpack_require__(345), 'atx'],
35245+
[__webpack_require__(345), "atx"],
3524835246
[
3524935247
__webpack_require__(346),
3525035248
[
35251-
{ no: 'Github', yes: 'GitHub' },
35252-
{ no: 'Javascript', yes: 'JavaScript' },
35253-
{ no: 'Node.JS', yes: 'Node.js' },
35254-
{ no: 'v8', yes: 'V8' }
35249+
{ no: "End-Of-Life", yes: "End-of-Life" },
35250+
{ no: "Github", yes: "GitHub" },
35251+
{ no: "Javascript", yes: "JavaScript" },
35252+
{ no: "Node.JS", yes: "Node.js" },
35253+
{ no: "v8", yes: "V8" }
3525535254
]
3525635255
],
35257-
[__webpack_require__(347), '*'],
35258-
[__webpack_require__(348), 'padded']
35256+
[__webpack_require__(347), "*"],
35257+
[__webpack_require__(348), "padded"]
3525935258
];
3526035259

3526135260

@@ -36842,7 +36841,7 @@ module.exports = {"addendum":"addenda","aircraft":"aircraft","alga":"algae","alu
3684236841
* Options: `number`, default: `80`.
3684336842
*
3684436843
* Ignores nodes that cannot be wrapped, such as headings, tables,
36845-
* code, and definitions.
36844+
* code, definitions, HTML, and JSX.
3684636845
*
3684736846
* Ignores images, links, and inline code if they start before the wrap, end
3684836847
* after the wrap, and there’s no white-space after them.
@@ -36868,6 +36867,8 @@ module.exports = {"addendum":"addenda","aircraft":"aircraft","alga":"algae","alu
3686836867
* | -- | --------- | -- | ---- | ------ | -- | ---- | ------ | ------- | ----- | ----- | ---- |
3686936868
* | be | helped | | | | | | | | | | . |
3687036869
*
36870+
* <a><b><i><p><q><s><u>alpha bravo charlie delta echo foxtrot golf</u></s></q></p></i></b></a>
36871+
*
3687136872
* The following is also fine, because there is no white-space.
3687236873
*
3687336874
* <http://this-long-url-with-a-long-domain-is-invalid.co.uk/a-long-path?query=variables>.
@@ -36941,10 +36942,11 @@ function maximumLineLength(tree, file, pref) {
3694136942
var index = -1
3694236943
var lineLength
3694336944

36944-
visit(tree, ['heading', 'table', 'code', 'definition'], ignore)
36945+
// Note: JSX is from MDX: <https://github.com/mdx-js/specification>.
36946+
visit(tree, ['heading', 'table', 'code', 'definition', 'html', 'jsx'], ignore)
3694536947
visit(tree, ['link', 'image', 'inlineCode'], inline)
3694636948

36947-
/* Iterate over every line, and warn for violating lines. */
36949+
// Iterate over every line, and warn for violating lines.
3694836950
while (++index < length) {
3694936951
lineLength = lines[index].length
3695036952

@@ -36956,9 +36958,9 @@ function maximumLineLength(tree, file, pref) {
3695636958
}
3695736959
}
3695836960

36959-
/* Finally, whitelist some inline spans, but only if they occur at or after
36960-
* the wrap. However, when they do, and there’s white-space after it, they
36961-
* are not whitelisted. */
36961+
// Finally, whitelist some inline spans, but only if they occur at or after
36962+
// the wrap. However, when they do, and there’s white-space after it, they
36963+
// are not whitelisted.
3696236964
function inline(node, pos, parent) {
3696336965
var next = parent.children[pos + 1]
3696436966
var initial
@@ -36972,13 +36974,12 @@ function maximumLineLength(tree, file, pref) {
3697236974
initial = start(node)
3697336975
final = end(node)
3697436976

36975-
/* No whitelisting when starting after the border, or ending before it. */
36977+
// No whitelisting when starting after the border, or ending before it.
3697636978
if (initial.column > style || final.column < style) {
3697736979
return
3697836980
}
3697936981

36980-
/* No whitelisting when there’s white-space after
36981-
* the link. */
36982+
// No whitelisting when there’s white-space after the link.
3698236983
if (
3698336984
next &&
3698436985
start(next).line === initial.line &&
@@ -36997,7 +36998,7 @@ function maximumLineLength(tree, file, pref) {
3699736998
}
3699836999
}
3699937000

37000-
/* Whitelist from `initial` to `final`, zero-based. */
37001+
// Whitelist from `initial` to `final`, zero-based.
3700137002
function whitelist(initial, final) {
3700237003
while (initial < final) {
3700337004
lines[initial++] = ''
@@ -39599,16 +39600,16 @@ function tableCellPadding(tree, file, pref) {
3959939600
var entry
3960039601
var final
3960139602

39602-
/* Check rows. */
39603+
// Check rows.
3960339604
while (++index < length) {
3960439605
row = rows[index]
3960539606
cells = row.children
3960639607
cellCount = cells.length
39607-
column = -2 /* Start without a first cell */
39608+
column = -2 // Start without a first cell.
3960839609
next = null
3960939610
final = undefined
3961039611

39611-
/* Check fences (before, between, and after cells) */
39612+
// Check fences (before, between, and after cells).
3961239613
while (++column < cellCount) {
3961339614
cell = next
3961439615
next = cells[column + 1]
@@ -39623,7 +39624,7 @@ function tableCellPadding(tree, file, pref) {
3962339624
if (cell && cell.children.length !== 0 && final !== undefined) {
3962439625
entries.push({node: cell, start: final, end: pos, index: column})
3962539626

39626-
/* Detect max space per column. */
39627+
// Detect max space per column.
3962739628
sizes[column] = Math.max(sizes[column] || 0, size(cell))
3962839629
} else {
3962939630
final = undefined
@@ -39670,7 +39671,7 @@ function tableCellPadding(tree, file, pref) {
3967039671
if (style === 0) {
3967139672
reason += 'compact'
3967239673

39673-
/* Ignore every cell except the biggest in the column. */
39674+
// Ignore every cell except the biggest in the column.
3967439675
if (size(cell) < sizes[index]) {
3967539676
return
3967639677
}
@@ -39680,7 +39681,7 @@ function tableCellPadding(tree, file, pref) {
3968039681
if (spacing > style) {
3968139682
reason += ' with 1 space, not ' + spacing
3968239683

39683-
/* May be right or center aligned. */
39684+
// May be right or center aligned.
3968439685
if (size(cell) < sizes[index]) {
3968539686
return
3968639687
}

0 commit comments

Comments
 (0)