Skip to content

Commit

Permalink
chore: update eslint-remote-tester config
Browse files Browse the repository at this point in the history
  • Loading branch information
aladdin-add committed Dec 2, 2024
1 parent 88a83c0 commit c3a4c69
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 17 deletions.
31 changes: 16 additions & 15 deletions eslint-remote-tester.config.js → eslint-remote-tester.config.mjs
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
'use strict';
import eslintPlugin from "eslint-plugin-eslint-plugin";

Check failure on line 1 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Replace `"eslint-plugin-eslint-plugin"` with `'eslint-plugin-eslint-plugin'`

Check failure on line 1 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Replace `"eslint-plugin-eslint-plugin"` with `'eslint-plugin-eslint-plugin'`
import tsparser from "@typescript-eslint/parser";

Check failure on line 2 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Replace `"@typescript-eslint/parser"` with `'@typescript-eslint/parser'`

Check failure on line 2 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Replace `"@typescript-eslint/parser"` with `'@typescript-eslint/parser'`

/** @type {import('eslint-remote-tester').Config} */
module.exports = {
export default {
/** Repositories to scan */
repositories: [
// A few dozen top ESLint plugins.
Expand Down Expand Up @@ -41,18 +42,18 @@ module.exports = {
/** Optional boolean flag used to enable caching of cloned repositories. For CIs it's ideal to disable caching. Defaults to true. */
cache: false,

pathIgnorePattern: 'fixtures',

/** ESLint configuration */
eslintrc: {
root: true,
extends: ['plugin:eslint-plugin/all'],
// ignorePatterns: ['fixtures/**/*'], // not working somehow - using `pathIgnorePattern` as of now.
overrides: [
{
files: ['*.ts', '*.mts', '*.cts'],
parser: '@typescript-eslint/parser',
},
],
},
eslintConfig: [
{
files: ["**/*.{js,mjs,cjs,ts,mts,cts}"],

Check failure on line 48 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Replace `"**/*.{js,mjs,cjs,ts,mts,cts}"` with `'**/*.{js,mjs,cjs,ts,mts,cts}'`

Check failure on line 48 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Replace `"**/*.{js,mjs,cjs,ts,mts,cts}"` with `'**/*.{js,mjs,cjs,ts,mts,cts}'`
...eslintPlugin.configs['flat/all'],
},
{
files: ['*.ts', '*.mts', '*.cts'],
...eslintPlugin.configs['flat/all-type-checked'],
languageOptions: {
parser: tsparser,
}

Check failure on line 56 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Insert `,`

Check failure on line 56 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Insert `,`
},
]

Check failure on line 58 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Insert `,`

Check failure on line 58 in eslint-remote-tester.config.mjs

View workflow job for this annotation

GitHub Actions / lint

Insert `,`
};
2 changes: 1 addition & 1 deletion eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ module.exports = [
'plugin:prettier/recommended',
'plugin:unicorn/recommended',
),
pluginN.configs['flat/recommended'],
...pluginN.configs['flat/mixed-esm-and-cjs'],
{
rules: {
'@eslint-community/eslint-comments/no-unused-disable': 'error',
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"lint:package-json": "npmPkgJsonLint .",
"release": "release-it",
"test": "nyc --all --check-coverage --include lib mocha tests --recursive",
"test:remote": "eslint-remote-tester",
"test:remote": "eslint-remote-tester -c eslint-remote-tester.config.mjs",
"update:eslint-docs": "eslint-doc-generator"
},
"files": [
Expand Down

0 comments on commit c3a4c69

Please sign in to comment.