Skip to content

Commit

Permalink
ci tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
msimerson committed Mar 26, 2022
1 parent 29c0878 commit b8528e5
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 14 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/ci-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ jobs:
with:
node-version: ${{ matrix.node-version }}

- name: npm install
run: npm install
- run: npm install

- name: Run test suite
run: npm run test
11 changes: 9 additions & 2 deletions .github/workflows/coveralls.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ on: [ pull_request ]

name: Coverage

env:
CI: true

jobs:

coverage:
Expand All @@ -21,11 +24,15 @@ jobs:
with:
node-version: 14

- name: install, run
- name: npm install
run: |
npm install
npm install --no-save nyc codecov
npm run cover
- name: run coverage
run: npx nyc --reporter=lcovonly npm run test
env:
NODE_ENV: cov

- name: Coveralls
uses: coverallsapp/github-action@master
Expand Down
11 changes: 5 additions & 6 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ name: Lint

on: [ push ]

env:
CI: true

jobs:

lint:
Expand All @@ -24,11 +27,7 @@ jobs:
with:
node-version: ${{ matrix.node-version }}

- name: npm install
run: npm install
- run: npm install

- name: Lint using eslint
- name: Lint
run: npm run lint

env:
CI: true
16 changes: 13 additions & 3 deletions .github/workflows/master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:
- master

env:
CI: true
node_version: 14

jobs:
Expand All @@ -26,10 +27,9 @@ jobs:
node-version: ${{ env.node_version }}
registry-url: https://registry.npmjs.org/

- name: npm install
run: npm install
- run: npm install

- name: Run test suite
- name: Run tests
run: npm run test

- name: publish to NPM
Expand All @@ -40,3 +40,13 @@ jobs:
- name: GitHub Release
uses: justincy/github-action-npm-release@2.0.1
id: release

- name: Coverage Run
run: |
npm install --no-save nyc codecov
npx nyc --reporter=lcovonly npm run test
- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"description": "DNS Zone Validator",
"main": "index.js",
"scripts": {
"cover": "NODE_ENV=cov npx nyc --reporter=lcovonly npm run test",
"grammar": "npx -p nearley nearleyc src/bind-grammar.ne -o lib/grammar.js",
"lint": "npx eslint index.js test/*.js",
"lintfix": "npx eslint --fix index.js test/*.js",
Expand Down

0 comments on commit b8528e5

Please sign in to comment.