From b7f8a44c648e477c7e402294f825b685363a8674 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Sat, 12 Nov 2022 06:48:52 -0800 Subject: [PATCH] tools: simplify regex in ESLint config MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PR-URL: https://github.com/nodejs/node/pull/45399 Reviewed-By: Michaƫl Zasso Reviewed-By: Antoine du Hamel Reviewed-By: Yagiz Nizipli Reviewed-By: Colin Ihrig Reviewed-By: Luigi Pinca --- .eslintrc.js | 3 +-- test/parallel/test-fs-readv-promises.js | 2 -- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index 64d35736b9ce77..0f90cb076ae45c 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -126,8 +126,7 @@ module.exports = { line: { // Ignore all lines that have less characters than 20 and all lines that // start with something that looks like a variable name or code. - // eslint-disable-next-line max-len - ignorePattern: '.{0,20}$|[a-z]+ ?[0-9A-Z_.(/=:[#-]|std|http|ssh|ftp|(let|var|const) [a-z_A-Z0-9]+ =|[b-z] |[a-z]*[0-9].* ', + ignorePattern: '.{0,20}$|[a-z]+ ?[0-9A-Z_.(/=:[#-]|std|http|ssh|ftp', ignoreInlineComments: true, ignoreConsecutiveComments: true, }, diff --git a/test/parallel/test-fs-readv-promises.js b/test/parallel/test-fs-readv-promises.js index ae3c92926ea221..3d698f2536a7f2 100644 --- a/test/parallel/test-fs-readv-promises.js +++ b/test/parallel/test-fs-readv-promises.js @@ -29,7 +29,6 @@ const allocateEmptyBuffers = (combinedLength) => { const filename = getFileName(); await fs.writeFile(filename, exptectedBuff); const handle = await fs.open(filename, 'r'); - // const buffer = Buffer.from(expected); const bufferArr = allocateEmptyBuffers(exptectedBuff.length); const expectedLength = exptectedBuff.length; @@ -49,7 +48,6 @@ const allocateEmptyBuffers = (combinedLength) => { const filename = getFileName(); await fs.writeFile(filename, exptectedBuff); const handle = await fs.open(filename, 'r'); - // const buffer = Buffer.from(expected); const bufferArr = allocateEmptyBuffers(exptectedBuff.length); const expectedLength = exptectedBuff.length;