Skip to content

Commit 57c8624

Browse files
authored
💥 drop Node.js 6 and switch CI to GitHub Actions (#60)
* 💥 drop Node.js 6 and switch CI to GitHub Actions
1 parent 93ce0ca commit 57c8624

File tree

4 files changed

+89
-35
lines changed

4 files changed

+89
-35
lines changed

Diff for: ‎.github/workflows/CI.yml

+81
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
name: CI
2+
on:
3+
push:
4+
branches: [master]
5+
pull_request:
6+
branches: [master]
7+
schedule:
8+
- cron: 0 0 * * 0
9+
10+
jobs:
11+
lint:
12+
name: Lint
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v1
17+
with:
18+
fetch-depth: 1
19+
- name: Checkout submodules
20+
run: git submodule update --init
21+
- name: Install Node.js
22+
uses: actions/setup-node@v1
23+
with:
24+
node-version: 12
25+
- name: Install Packages
26+
run: npm install
27+
- name: Lint
28+
run: npm run -s lint
29+
30+
test:
31+
name: Test
32+
33+
strategy:
34+
matrix:
35+
eslint: [6, 5]
36+
node: [13, 12, 10, 8, "8.10.0"]
37+
exclude:
38+
# Run ESLint 5 on only the LTS.
39+
- node: 13
40+
eslint: 5
41+
- node: 10
42+
eslint: 5
43+
- node: 8
44+
eslint: 5
45+
- node: "8.10.0"
46+
eslint: 5
47+
48+
runs-on: ubuntu-latest
49+
steps:
50+
- name: Checkout
51+
uses: actions/checkout@v1
52+
with:
53+
fetch-depth: 1
54+
- name: Checkout submodules
55+
run: git submodule update --init
56+
- name: Install Node.js v${{ matrix.node }}
57+
uses: actions/setup-node@v1
58+
with:
59+
node-version: ${{ matrix.node }}
60+
- name: Install Packages
61+
run: npm install
62+
- name: Install ESLint v${{ matrix.eslint }}
63+
run: |
64+
if [ ${{ matrix.eslint }} -eq 6 ]; then
65+
cd test/fixtures/eslint
66+
npm install
67+
else
68+
npm install --no-save [email protected]
69+
cd test/fixtures/eslint
70+
git checkout v5.16.0
71+
npm install [email protected]
72+
npm install
73+
fi
74+
- name: Build
75+
run: npm run -s build
76+
- name: Test
77+
run: npm run -s test:mocha
78+
- name: Send Coverage
79+
run: npm run -s codecov
80+
env:
81+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

Diff for: ‎.travis.yml

-28
This file was deleted.

Diff for: ‎README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![npm version](https://img.shields.io/npm/v/vue-eslint-parser.svg)](https://www.npmjs.com/package/vue-eslint-parser)
44
[![Downloads/month](https://img.shields.io/npm/dm/vue-eslint-parser.svg)](http://www.npmtrends.com/vue-eslint-parser)
5-
[![Build Status](https://travis-ci.org/mysticatea/vue-eslint-parser.svg?branch=master)](https://travis-ci.org/mysticatea/vue-eslint-parser)
5+
[![Build Status](https://github.com/mysticatea/vue-eslint-parser/workflows/CI/badge.svg)](https://github.com/mysticatea/vue-eslint-parser/actions)
66
[![Coverage Status](https://codecov.io/gh/mysticatea/vue-eslint-parser/branch/master/graph/badge.svg)](https://codecov.io/gh/mysticatea/vue-eslint-parser)
77
[![Dependency Status](https://david-dm.org/mysticatea/vue-eslint-parser.svg)](https://david-dm.org/mysticatea/vue-eslint-parser)
88

Diff for: ‎package.json

+7-6
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,20 @@
33
"version": "6.0.5",
44
"description": "The ESLint custom parser for `.vue` files.",
55
"engines": {
6-
"node": ">=6.5"
6+
"node": ">=8.10"
77
},
88
"main": "index.js",
99
"files": [
1010
"index.*"
1111
],
1212
"peerDependencies": {
13-
"eslint": "^5.0.0 || ^6.0.0"
13+
"eslint": ">=5.0.0"
1414
},
1515
"dependencies": {
1616
"debug": "^4.1.1",
17-
"eslint-scope": "^4.0.0 || ^5.0.0",
18-
"eslint-visitor-keys": "^1.0.0",
19-
"espree": "^5.0.0 || ^6.0.0",
17+
"eslint-scope": "^5.0.0",
18+
"eslint-visitor-keys": "^1.1.0",
19+
"espree": "^6.1.2",
2020
"esquery": "^1.0.1",
2121
"lodash": "^4.17.15"
2222
},
@@ -57,7 +57,8 @@
5757
"lint": "node -e \"if(process.env.ESLINT=='5')process.exit(1)\" && eslint src test --ext .js,.ts || node -e \"if(process.env.ESLINT!='5')process.exit(1)\"",
5858
"setup": "git submodule update --init && cd test/fixtures/eslint && npm install",
5959
"pretest": "run-s build lint",
60-
"test": "nyc mocha \"test/*.js\" --reporter dot --timeout 10000",
60+
"test": "npm run -s test:mocha",
61+
"test:mocha": "nyc mocha \"test/*.js\" --reporter dot --timeout 10000",
6162
"preupdate-fixtures": "npm run -s build",
6263
"update-fixtures": "node scripts/update-fixtures-ast.js",
6364
"preversion": "npm test",

0 commit comments

Comments
 (0)