Update Bot (j'ai plus le repo sur GitHub)
Qui c'est la conne qui a delete le repo sur GitHub? C'EST MOIIIII
This commit is contained in:
2
node_modules/eslint/lib/linter/esquery.js
generated
vendored
2
node_modules/eslint/lib/linter/esquery.js
generated
vendored
@@ -90,7 +90,7 @@ class ESQueryParsedSelector {
|
||||
}
|
||||
|
||||
/**
|
||||
* Compares this selector's specifity to another selector for sorting purposes.
|
||||
* Compares this selector's specificity to another selector for sorting purposes.
|
||||
* @param {ESQueryParsedSelector} otherSelector The selector to compare against
|
||||
* @returns {number}
|
||||
* a value less than 0 if this selector is less specific than otherSelector
|
||||
|
||||
2
node_modules/eslint/lib/linter/file-report.js
generated
vendored
2
node_modules/eslint/lib/linter/file-report.js
generated
vendored
@@ -426,7 +426,7 @@ function validateSuggestions(suggest, messages) {
|
||||
|
||||
if (typeof suggestion.fix !== "function") {
|
||||
throw new TypeError(
|
||||
`context.report() called with a suggest option without a fix function. See: ${suggestion}`,
|
||||
`context.report() called with a suggest option without a fix function. See: ${JSON.stringify(suggestion, null, 2)}`,
|
||||
);
|
||||
}
|
||||
});
|
||||
|
||||
14
node_modules/eslint/lib/linter/linter.js
generated
vendored
14
node_modules/eslint/lib/linter/linter.js
generated
vendored
@@ -1921,6 +1921,20 @@ class Linter {
|
||||
});
|
||||
}
|
||||
} else {
|
||||
if (config.language === jslang) {
|
||||
for (const comment of sourceCode.getInlineConfigNodes()) {
|
||||
const { label } = commentParser.parseDirective(
|
||||
comment.value,
|
||||
);
|
||||
if (label === "eslint-env") {
|
||||
slots.warningService.emitESLintEnvWarning(
|
||||
options.filename,
|
||||
comment.loc.start.line,
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const inlineConfigResult = sourceCode.applyInlineConfig?.();
|
||||
|
||||
if (inlineConfigResult) {
|
||||
|
||||
16
node_modules/eslint/lib/linter/source-code-traverser.js
generated
vendored
16
node_modules/eslint/lib/linter/source-code-traverser.js
generated
vendored
@@ -17,8 +17,9 @@ const vk = require("eslint-visitor-keys");
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
/**
|
||||
* @import { ESQueryParsedSelector } from "./esquery.js";
|
||||
* @import { Language, SourceCode } from "@eslint/core";
|
||||
* @import { ESQueryOptions } from "esquery";
|
||||
* @import { ESQueryParsedSelector } from "./esquery.js";
|
||||
* @import { SourceCodeVisitor } from "./source-code-visitor.js";
|
||||
*/
|
||||
|
||||
@@ -47,11 +48,10 @@ class ESQueryHelper {
|
||||
* Creates a new instance.
|
||||
* @param {SourceCodeVisitor} visitor The visitor containing the functions to call.
|
||||
* @param {ESQueryOptions} esqueryOptions `esquery` options for traversing custom nodes.
|
||||
* @returns {NodeEventGenerator} new instance
|
||||
*/
|
||||
constructor(visitor, esqueryOptions) {
|
||||
/**
|
||||
* The emitter to use during traversal.
|
||||
* The visitor to use during traversal.
|
||||
* @type {SourceCodeVisitor}
|
||||
*/
|
||||
this.visitor = visitor;
|
||||
@@ -288,7 +288,10 @@ class SourceCodeTraverser {
|
||||
false,
|
||||
)
|
||||
.forEach(selector => {
|
||||
visitor.callSync(selector, step.target);
|
||||
visitor.callSync(
|
||||
selector,
|
||||
...(step.args ?? [step.target]),
|
||||
);
|
||||
});
|
||||
currentAncestry.unshift(step.target);
|
||||
} else {
|
||||
@@ -300,7 +303,10 @@ class SourceCodeTraverser {
|
||||
true,
|
||||
)
|
||||
.forEach(selector => {
|
||||
visitor.callSync(selector, step.target);
|
||||
visitor.callSync(
|
||||
selector,
|
||||
...(step.args ?? [step.target]),
|
||||
);
|
||||
});
|
||||
}
|
||||
} catch (err) {
|
||||
|
||||
39
node_modules/eslint/lib/linter/timing.js
generated
vendored
39
node_modules/eslint/lib/linter/timing.js
generated
vendored
@@ -131,6 +131,7 @@ function display(data) {
|
||||
/* c8 ignore next */
|
||||
module.exports = (function () {
|
||||
const data = Object.create(null);
|
||||
let displayEnabled = true;
|
||||
|
||||
/**
|
||||
* Time the run
|
||||
@@ -158,9 +159,42 @@ module.exports = (function () {
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a shallow copy of the collected timings data.
|
||||
* @returns {Record<string, number>} mapping of ruleId to total time in ms
|
||||
*/
|
||||
function getData() {
|
||||
return { ...data };
|
||||
}
|
||||
|
||||
/**
|
||||
* Merges rule timing totals collected elsewhere into this process' totals.
|
||||
* @param {Record<string, number>} dataToMerge mapping of ruleId to total time in ms
|
||||
* @returns {void}
|
||||
*/
|
||||
function mergeData(dataToMerge) {
|
||||
for (const [key, value] of Object.entries(dataToMerge)) {
|
||||
if (typeof data[key] === "undefined") {
|
||||
data[key] = 0;
|
||||
}
|
||||
data[key] += value;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Disables printing of timing data on process exit.
|
||||
* Intended for worker threads or non-main contexts.
|
||||
* @returns {void}
|
||||
*/
|
||||
function disableDisplay() {
|
||||
displayEnabled = false;
|
||||
}
|
||||
|
||||
if (enabled) {
|
||||
process.on("exit", () => {
|
||||
display(data);
|
||||
if (displayEnabled && Object.keys(data).length > 0) {
|
||||
display(data);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -168,5 +202,8 @@ module.exports = (function () {
|
||||
time,
|
||||
enabled,
|
||||
getListSize,
|
||||
getData,
|
||||
mergeData,
|
||||
disableDisplay,
|
||||
};
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user