Skip to content

Commit

Permalink
Merge pull request #167 from Financial-Times/nori/upgrade-node
Browse files Browse the repository at this point in the history
Upgrade to Node 14/16
  • Loading branch information
ivomurrell authored Mar 18, 2022
2 parents c4cb061 + 386f1cd commit 7a98406
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 8 deletions.
53 changes: 48 additions & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,12 @@ orbs:
executors:
circleci-node:
docker:
- image: cimg/node:12.22
- image: cimg/node:<< parameters.node-version >>
working_directory: ~/project/build-node
parameters:
node-version:
default: "16.14"
type: string

commands:
npm-install:
Expand All @@ -21,15 +25,18 @@ references:
#
# Workspace
#

workspace_root: &workspace_root ~/project

attach_workspace:
&attach_workspace
attach_workspace:
at: *workspace_root

#
# Filters
#

filters_only_renovate_nori:
&filters_only_renovate_nori
branches:
Expand All @@ -54,6 +61,10 @@ references:
jobs:
build-node:
executor: circleci-node
parameters:
node-version:
default: "16.14"
type: string
steps:
- checkout
- node/install-npm:
Expand All @@ -65,6 +76,10 @@ jobs:
- build-node
test-node:
executor: circleci-node
parameters:
node-version:
default: "16.14"
type: string
steps:
- *attach_workspace
- run:
Expand All @@ -73,6 +88,10 @@ jobs:

publish:
executor: circleci-node
parameters:
node-version:
default: "16.14"
type: string
steps:
- *attach_workspace
- run:
Expand Down Expand Up @@ -103,9 +122,17 @@ workflows:
- build-node:
filters:
<<: *filters_branch_build_renovate_nori
name: build-node-v<< matrix.node-version >>
matrix:
parameters:
node-version: [ "16.14", "14.19" ]
- test-node:
requires:
- build-node
- build-node-v<< matrix.node-version >>
name: test-node-v<< matrix.node-version >>
matrix:
parameters:
node-version: [ "16.14", "14.19" ]

renovate-nori-build-test:
jobs:
Expand All @@ -116,23 +143,39 @@ workflows:
- build-node:
requires:
- waiting-for-approval
name: build-node-v<< matrix.node-version >>
matrix:
parameters:
node-version: [ "16.14", "14.19" ]
- test-node:
requires:
- build-node
- build-node-v<< matrix.node-version >>
name: test-node-v<< matrix.node-version >>
matrix:
parameters:
node-version: [ "16.14", "14.19" ]

build-test-publish:
jobs:
- build-node:
filters:
<<: *filters_release_package_build
name: build-node-v<< matrix.node-version >>
matrix:
parameters:
node-version: [ "16.14", "14.19" ]
- test-node:
filters:
<<: *filters_release_package_build
requires:
- build-node
- build-node-v<< matrix.node-version >>
name: test-node-v<< matrix.node-version >>
matrix:
parameters:
node-version: [ "16.14", "14.19" ]
- publish:
context: npm-publish-token
filters:
<<: *filters_release_package_build
requires:
- test-node
- test-node-v16.14
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
12
16
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
},
"homepage": "https://github.com/Financial-Times/ebi#readme",
"engines": {
"node": "12.x",
"node": "14.x || 16.x",
"npm": "7.x || 8.x"
},
"husky": {
Expand All @@ -63,7 +63,7 @@
"prettier": "1.17.0"
},
"volta": {
"node": "12.22.5",
"node": "16.14.1",
"npm": "7.20.2"
}
}

0 comments on commit 7a98406

Please sign in to comment.