Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit fe4f38c

Browse files
committedJan 24, 2025··
feat: drop ESLint v2, v3, v4, v5, v6 & v7 support
BREAKING CHANGE: Requires ESLint@^8.57.0 || ^9.0.0
1 parent 2afd06d commit fe4f38c

File tree

5 files changed

+10
-53
lines changed

5 files changed

+10
-53
lines changed
 

‎.github/workflows/native-wsl.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
- name: 'WSL: do all npm install steps'
3030
if: matrix.configuration == 'wsl'
3131
env:
32-
ESLINT_VERSION: 7
32+
ESLINT_VERSION: 9
3333
run: |
3434
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash
3535
export NVM_DIR="$HOME/.nvm"
@@ -52,7 +52,7 @@ jobs:
5252
- name: copy metafiles in Native
5353
if: matrix.configuration == 'native'
5454
env:
55-
ESLINT_VERSION: 7
55+
ESLINT_VERSION: 9
5656
run: |
5757
npm run copy-metafiles
5858
bash ./tests/dep-time-travel.sh 2>&1

‎.github/workflows/node.yml

+2-22
Original file line numberDiff line numberDiff line change
@@ -37,29 +37,9 @@ jobs:
3737
node-version: ${{ fromJson(needs.matrix.outputs.latest) }}
3838
eslint:
3939
- 9
40+
- 9.0.0
4041
- 8
41-
- 7
42-
- 6
43-
- 5
44-
- 4
45-
- 3
46-
- 2
47-
include:
48-
- node-version: 'lts/*'
49-
os: ubuntu-latest
50-
eslint: 7
51-
env:
52-
TS_PARSER: 4
53-
- node-version: 'lts/*'
54-
os: ubuntu-latest
55-
eslint: 7
56-
env:
57-
TS_PARSER: 3
58-
- node-version: 'lts/*'
59-
os: ubuntu-latest
60-
eslint: 7
61-
env:
62-
TS_PARSER: 2
42+
- 8.57.0
6343

6444
steps:
6545
- uses: actions/checkout@v4

‎.github/workflows/packages.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,10 @@ jobs:
3333
matrix:
3434
node-version: ${{ fromJson(needs.matrix.outputs.latest) }}
3535
eslint:
36+
- 9
37+
- 9.0.0
3638
- 8
37-
- 7
39+
- 8.57.0
3840
package:
3941
- resolvers/node
4042
- resolvers/webpack

‎package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@
8181
"chai": "^4.3.10",
8282
"cross-env": "^4.0.0",
8383
"escope": "^3.6.0",
84-
"eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 || ^9",
84+
"eslint": "^8.57.0 || ^9.0.0",
8585
"eslint-doc-generator": "^1.6.1",
8686
"eslint-import-resolver-node": "file:./resolvers/node",
8787
"eslint-import-resolver-typescript": "^1.0.2 || ^1.1.1",
@@ -112,7 +112,7 @@
112112
"typescript-eslint-parser": "^15 || ^20 || ^22"
113113
},
114114
"peerDependencies": {
115-
"eslint": "^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 || ^9"
115+
"eslint": "^8.57.0 || ^9.0.0"
116116
},
117117
"dependencies": {
118118
"@rtsao/scc": "^1.1.0",

‎tests/dep-time-travel.sh

+1-26
Original file line numberDiff line numberDiff line change
@@ -2,37 +2,12 @@
22

33
# expected: ESLINT_VERSION numeric env var
44

5-
echo "installing ${ESLINT_VERSION} with TS parser ${TS_PARSER:-default}..."
5+
echo "installing ${ESLINT_VERSION}..."
66

77
export NPM_CONFIG_LEGACY_PEER_DEPS=true
88

9-
if [[ "$ESLINT_VERSION" -lt "7" ]]; then
10-
echo "Removing @angular-eslint/template-parser..."
11-
npm uninstall --no-save @angular-eslint/template-parser
12-
fi
13-
149
npm install --no-save "eslint@${ESLINT_VERSION}" --ignore-scripts
1510

16-
if [[ -n "$TS_PARSER" ]]; then # if TS parser is manually set, always use it
17-
echo "Downgrading @typescript-eslint/parser..."
18-
npm i --no-save "@typescript-eslint/parser@${TS_PARSER}"
19-
elif [[ "$ESLINT_VERSION" -lt "5" ]]; then # completely remove the new TypeScript parser for ESLint < v5
20-
echo "Removing @typescript-eslint/parser..."
21-
npm uninstall --no-save @typescript-eslint/parser
22-
fi
23-
24-
# use these alternate TypeScript dependencies for ESLint < v4
25-
if [[ "$ESLINT_VERSION" -lt "4" ]]; then
26-
echo "Downgrading babel-eslint..."
27-
npm i --no-save babel-eslint@8.0.3
28-
29-
echo "Downgrading TypeScript dependencies..."
30-
npm i --no-save typescript-eslint-parser@15 typescript@2.8.1
31-
elif [[ "$ESLINT_VERSION" -lt "7" ]]; then
32-
echo "Downgrading TypeScript dependencies..."
33-
npm i --no-save typescript-eslint-parser@20
34-
fi
35-
3611
if [ "${ESLINT_VERSION}" = '8' ]; then
3712
# This is a workaround for the crash in the initial processing of the ESLint class.
3813
echo "Installing self"

0 commit comments

Comments
 (0)
Please sign in to comment.