Skip to content

Commit

Permalink
chore(*): de-support node 8, add node 14 to build matrices (#288)
Browse files Browse the repository at this point in the history
* chore(*): de-support node 8, add node 14 to build matrices
* build(npm): ⬆️ ajv, chalk, commander, eslint-config-prettier, eslint-plugin-unicorn, husky, lint-staged, prettier, semver, strip-json-comments, teamcity-service-messages, wrap-ansi
  • Loading branch information
sverweij authored Apr 25, 2020
1 parent e26ea16 commit 150b12e
Show file tree
Hide file tree
Showing 200 changed files with 2,022 additions and 2,053 deletions.
2 changes: 1 addition & 1 deletion .codeclimate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ checks:
config:
threshold: 32
# removed the eslint plugin. The eslint ecosystem moves faster
# than what codeclimate can keep upt with - and we're running
# than what codeclimate can keep up with - and we're running
# eslint on other ci platforms anyway now.
exclude_patterns:
- ".github/"
Expand Down
110 changes: 54 additions & 56 deletions .github/workflows/lint-test-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,77 +2,75 @@ name: linting & test coverage - linux

on:
push:
branches:
branches:
- master
- develop
pull_request:

jobs:

check:

strategy:
fail-fast: false
matrix:
node-version:
- ^8.12
node-version:
- 10.x
- 12.x
- 13.x
- 14.x
platform:
- ubuntu-latest

runs-on: ${{matrix.platform}}

steps:
- name: checkout
uses: actions/checkout@v1
- name: cache node modules for ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/cache@v1
with:
path: node_modules
key: ${{matrix.node-version}}@${{matrix.platform}}-build-${{hashFiles('package.json')}}
restore-keys: |
${{matrix.node-version}}@${{matrix.platform}}-build-
- name: set up node ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/setup-node@v1
with:
node-version: ${{matrix.node-version}}
- name: install & build
run: |
node --version
npm install
npm run build
shell: bash
env:
CI: true
- name: cache eslint for ${{matrix.node-version}}@${{matrix.platform}} (run on one platform only)
uses: actions/cache@v1
with:
path: .cache
key: ${{matrix.node-version}}@${{matrix.platform}}-build-eslint-${{hashFiles('package.json')}}
restore-keys: |
${{matrix.node-version}}@${{matrix.platform}}-build-eslint-
if: matrix.platform == 'ubuntu-latest' && matrix.node-version == '13.x'
- name: lint (run on one platform only)
run: |
node --version
npm run lint
if: matrix.platform == 'ubuntu-latest' && matrix.node-version == '13.x'
shell: bash
env:
CI: true
- name: forbidden dependency check
run: |
node --version
npm run depcruise
shell: bash
env:
CI: true
- name: test coverage
run: |
node --version
npm run test:cover
shell: bash
env:
CI: true
- name: checkout
uses: actions/checkout@v1
- name: cache node modules for ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/cache@v1
with:
path: node_modules
key: ${{matrix.node-version}}@${{matrix.platform}}-build-${{hashFiles('package.json')}}
restore-keys: |
${{matrix.node-version}}@${{matrix.platform}}-build-
- name: set up node ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/setup-node@v1
with:
node-version: ${{matrix.node-version}}
- name: install & build
run: |
node --version
npm install
npm run build
shell: bash
env:
CI: true
- name: cache eslint for ${{matrix.node-version}}@${{matrix.platform}} (run on one platform only)
uses: actions/cache@v1
with:
path: .cache
key: ${{matrix.node-version}}@${{matrix.platform}}-build-eslint-${{hashFiles('package.json')}}
restore-keys: |
${{matrix.node-version}}@${{matrix.platform}}-build-eslint-
if: matrix.platform == 'ubuntu-latest' && matrix.node-version == '14.x'
- name: lint (run on one platform only)
run: |
node --version
npm run lint
if: matrix.platform == 'ubuntu-latest' && matrix.node-version == '14.x'
shell: bash
env:
CI: true
- name: forbidden dependency check
run: |
node --version
npm run depcruise
shell: bash
env:
CI: true
- name: test coverage
run: |
node --version
npm run test:cover
shell: bash
env:
CI: true
78 changes: 38 additions & 40 deletions .github/workflows/test-workflow-windows-only.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,58 +2,56 @@ name: test coverage - windows

on:
push:
branches:
branches:
- master
- develop
pull_request:

jobs:

check:

strategy:
fail-fast: false
matrix:
node-version:
- 12.x
node-version:
- 14.x
platform:
- windows-latest

runs-on: ${{matrix.platform}}

steps:
- name: checkout
uses: actions/checkout@v1
- name: cache node modules for ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/cache@v1
with:
path: node_modules
key: ${{matrix.node-version}}@${{matrix.platform}}-build-${{hashFiles('package.json')}}
restore-keys: |
${{matrix.node-version}}@${{matrix.platform}}-build-
- name: set up node ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/setup-node@v1
with:
node-version: ${{matrix.node-version}}
- name: install & build
run: |
node --version
npm install
npm run build
shell: bash
env:
CI: true
- name: forbidden dependency check
run: |
node --version
npm run depcruise
shell: bash
env:
CI: true
- name: test coverage
run: |
node --version
npm run test:cover
shell: bash
env:
CI: true
- name: checkout
uses: actions/checkout@v1
- name: cache node modules for ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/cache@v1
with:
path: node_modules
key: ${{matrix.node-version}}@${{matrix.platform}}-build-${{hashFiles('package.json')}}
restore-keys: |
${{matrix.node-version}}@${{matrix.platform}}-build-
- name: set up node ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/setup-node@v1
with:
node-version: ${{matrix.node-version}}
- name: install & build
run: |
node --version
npm install
npm run build
shell: bash
env:
CI: true
- name: forbidden dependency check
run: |
node --version
npm run depcruise
shell: bash
env:
CI: true
- name: test coverage
run: |
node --version
npm run test:cover
shell: bash
env:
CI: true
47 changes: 23 additions & 24 deletions .github/workflows/yarn-integration-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,43 +2,42 @@ name: yarn pnp integration test

on:
push:
branches:
branches:
- master
- develop
pull_request:

jobs:
integration:

strategy:
fail-fast: false
matrix:
node-version:
node-version:
- 12.x
- 13.x
- 14.x
platform:
- ubuntu-latest

runs-on: ${{matrix.platform}}

steps:
- name: checkout
uses: actions/checkout@v1
- name: set up node ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/setup-node@v1
with:
node-version: ${{matrix.node-version}}
- name: install
run: |
node --version
npm install
shell: bash
env:
CI: true
- name: forbidden dependency checks in a yarn pnp environment
run: |
node --version
npm run test:yarn-pnp
shell: bash
env:
CI: true
- name: checkout
uses: actions/checkout@v1
- name: set up node ${{matrix.node-version}}@${{matrix.platform}}
uses: actions/setup-node@v1
with:
node-version: ${{matrix.node-version}}
- name: install
run: |
node --version
npm install
shell: bash
env:
CI: true
- name: forbidden dependency checks in a yarn pnp environment
run: |
node --version
npm run test:yarn-pnp
shell: bash
env:
CI: true
19 changes: 5 additions & 14 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ cache:
paths:
- node_modules

test_async_node_13:
image: node:13
test_async_node_14:
image: node:14
script:
- npm install
- npm run lint
- npm run depcruise
# - npm run test:integration # yarn(1) pnp doesn't work on node 13 yet
- npm run test:yarn-pnp
- npm run test:cover
except:
- tags
Expand All @@ -19,7 +19,7 @@ test_async_node_12:
image: node:12
script:
- npm install
- npm run test:integration
- npm run test:yarn-pnp
- npm run test:cover
except:
- tags
Expand All @@ -28,16 +28,7 @@ test_async_node_10:
image: node:10
script:
- npm install
- npm run test:integration
- npm run test:cover
except:
- tags

test_async_node_8:
image: node:8
script:
- npm install
- npm run test:integration
- npm run test:yarn-pnp
- npm run test:cover
except:
- tags
Expand Down
2 changes: 1 addition & 1 deletion bin/wrap-stream-in-html.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ const wrap = require("../src/cli/tools/wrap-stream-in-html");
* interactive to use. Tailored to svg's generated by graphviz dot.
*/

wrap(process.stdin).then(pOutput => process.stdout.write(pOutput));
wrap(process.stdin).then((pOutput) => process.stdout.write(pOutput));
4 changes: 2 additions & 2 deletions configs/recommended-strict.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ const recommended = require("./recommended");

module.exports = {
...recommended,
forbidden: recommended.forbidden.map(pRule => {
forbidden: recommended.forbidden.map((pRule) => {
pRule.severity = "error";
return pRule;
})
}),
};
4 changes: 2 additions & 2 deletions configs/recommended-warn-only.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ const recommended = require("./recommended");

module.exports = {
...recommended,
forbidden: recommended.forbidden.map(pRule => {
forbidden: recommended.forbidden.map((pRule) => {
pRule.severity = "warn";
return pRule;
})
}),
};
Loading

0 comments on commit 150b12e

Please sign in to comment.