Skip to content

Commit

Permalink
build: add GitHub actions to run linters
Browse files Browse the repository at this point in the history
Add jobs to our GitHub Actions workflow to run our
various lint Makefile targets. The `setup-node` action
used to run the JavaScript linter contains problem
matchers for eslint that will annotate the files in a pull
request if there are failures.

PR-URL: #31323
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
  • Loading branch information
richardlau authored and Trott committed Jan 14, 2020
1 parent f4a4a1a commit cceef18
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,39 @@ jobs:
run: npx envinfo
- name: Build
run: ./configure && make -j8
lint-addon-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: 10.x
- name: Lint addon docs
run: NODE=$(which node) make lint-addon-docs
lint-cpp:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Lint C/C++ files
run: make lint-cpp
lint-md:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: 10.x
- name: Lint docs
run: NODE=$(which node) make lint-md
lint-js:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: 10.x
- name: Lint JavaScript files
run: NODE=$(which node) make lint-js

0 comments on commit cceef18

Please sign in to comment.