Skip to content

Commit

Permalink
fix: release when using node 18.19 (#63)
Browse files Browse the repository at this point in the history
* fix: release when using node 18.19
* chore: bump setup-node action version, pin to .tool-versions
* chore: bump checkout action version
  • Loading branch information
erikburt authored Dec 19, 2023
1 parent f70c2b1 commit a3d64da
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 37 deletions.
20 changes: 10 additions & 10 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,22 +21,22 @@ jobs:
with:
basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }}
hostname: ${{ secrets.GRAFANA_CLOUD_HOST }}
this-job-name: Upsert PR
this-job-name: Upsert PR
continue-on-error: true

- name: Checkout the repo
uses: actions/checkout@v3
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup node
uses: actions/setup-node@v3
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1
with:
node-version: "18"
node-version-file: .tool-versions
cache: yarn

- name: Run yarn install
run: yarn install --frozen-lockfile
- name: Upsert Release Pull Request

- name: Upsert Release Pull Request
id: changesets
uses: changesets/action@v1
env:
Expand All @@ -56,12 +56,12 @@ jobs:
continue-on-error: true

- name: Checkout the repo
uses: actions/checkout@v3
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup node
uses: actions/setup-node@v3
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1
with:
node-version: "18"
node-version-file: .tool-versions
cache: yarn

- name: Run yarn install
Expand All @@ -79,7 +79,7 @@ jobs:
run: yarn install --frozen-lockfile
working-directory: scripts

- name: Create Release
- name: Create Release
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: yarn -s release
Expand Down
18 changes: 9 additions & 9 deletions .github/workflows/chainlink-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
# This workflow is triggered whenever a pull_request event is triggered within
# the _smartcontractkit/chainlink_ repository. Then, the status of this workflow
# is returned back and propagated. See https://github.com/marketplace/actions/trigger-workflow-and-wait for more information
#
#
# PURPOSE
# This checks if breaking changes are made to the schema within a PR in the
# This checks if breaking changes are made to the schema within a PR in the
# smartcontractkit/chainlink repo, then fails if so. Schema changes should
# never be breaking. See https://graphql.org/learn/best-practices/#versioning

Expand All @@ -21,29 +21,29 @@ jobs:
detect-gql-breaking-changes:
name: Detect GQL Breaking Changes
runs-on: ubuntu-latest
steps:
steps:
- name: Collect Metrics
id: collect-gha-metrics
uses: smartcontractkit/push-gha-metrics-action@v1
with:
basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }}
hostname: ${{ secrets.GRAFANA_CLOUD_HOST }}
this-job-name: Detect GQL Breaking Changes
this-job-name: Detect GQL Breaking Changes
continue-on-error: true

- name: Checkout the repo
uses: actions/checkout@v3
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup node
uses: actions/setup-node@v3
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1
with:
node-version: "18"
node-version-file: .tool-versions
cache: yarn

- name: Run yarn install
run: yarn install --frozen-lockfile
- name: Test setup

- name: Test setup
run: yarn codegen
env:
GH_TOKEN: ${{ github.token }}
Expand Down
32 changes: 16 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,17 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout the repo
uses: actions/checkout@v2
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1

- name: Setup node
uses: actions/setup-node@v3
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1
with:
node-version: "18"
node-version-file: .tool-versions
cache: yarn

- name: Run yarn install
run: yarn install --frozen-lockfile

- name: Setup project
run: yarn setup
env:
Expand Down Expand Up @@ -56,52 +56,52 @@ jobs:
hostname: ${{ secrets.GRAFANA_CLOUD_HOST }}
this-job-name: Unit Tests ${{ matrix.shardIndex }}
continue-on-error: true

- name: Checkout the repo
uses: actions/checkout@v2
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
fetch-depth: 0 # required by CodCov

- name: Setup node
uses: actions/setup-node@v3
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1
with:
node-version: "18"
node-version-file: .tool-versions
cache: yarn

- name: Run yarn install
run: yarn install --frozen-lockfile

- name: Setup project
run: yarn setup
env:
GH_TOKEN: ${{ github.token }}

- name: Run tests
run: yarn run test:ci --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }}

- name: Upload CodCov coverage report
run: ./bin/codecov -s ./coverage

- name: Rename unit-test coverage report as belonging to the shard ${{ matrix.shardIndex }}
run: mv coverage/lcov.info coverage/${{matrix.shardIndex}}_lcov.info

- name: Upload unit-test coverage report
if: always()
uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0
with:
name: unit-tests-coverage
path: ./coverage/${{matrix.shardIndex}}_lcov.info

sonarqube:
name: SonarQube Scan
needs: [eslint, unit-tests]
runs-on: ubuntu-latest
if: always()
steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
fetch-depth: 0 # fetches all history for all tags and branches to provide more metadata for sonar reports

- name: Download all reports
uses: actions/download-artifact@9782bd6a9848b53b110e712e20e42d89988822b7 # v3.0.1

Expand Down
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1 +1 @@
nodejs 18.17.1
nodejs 18.19.0
2 changes: 1 addition & 1 deletion scripts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"license": "MIT",
"type": "module",
"scripts": {
"release": "ts-node -T --esm ./release.mts"
"release": "node --loader=ts-node/esm ./release.mts"
},
"dependencies": {
"@changesets/read": "^0.5.7",
Expand Down

0 comments on commit a3d64da

Please sign in to comment.