Skip to content

Update dependency typescript-eslint to ^8.18.2 #1753

Update dependency typescript-eslint to ^8.18.2

Update dependency typescript-eslint to ^8.18.2 #1753

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
schedule:
- cron: '15 0 * * *'
permissions:
contents: read
defaults:
run:
shell: bash
jobs:
test:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
node-version: [14, 16, 18, 20, 22]
coverage: [true]
include:
- os: ubuntu-latest
node-version: 12
coverage: false
- os: windows-latest
node-version: 12
coverage: false
exclude:
# macos-latest is now ARM, so exclude Node 12/14
- os: macos-latest
node-version: 14
runs-on: ${{ matrix.os }}
env:
OS: ${{ matrix.os }}
NODE: ${{ matrix.node-version }}
name: Test on ${{ matrix.os }} with Node.js ${{ matrix.node-version }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: '*'
- run: npm ci
if: ${{ github.event_name != 'schedule' }}
- shell: bash
run: |
npm install -g $(jq -r '.packageManager' < package.json)
rm package-lock.json
npm i
if: ${{ github.event_name == 'schedule' }}
- run: npm run build
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: ${{ matrix.node-version }}
check-latest: true
- run: npm run test
if: ${{ ! matrix.coverage }}
- run: npm run coverage
if: ${{ matrix.coverage }}
- uses: codecov/codecov-action@b9fd7d16f6d7d1b5d2bec1a2887e65ceed900238 # v4.6.0
if: ${{ matrix.coverage && github.event_name != 'schedule' }}
continue-on-error: true
timeout-minutes: 5
with:
token: ${{ secrets.CODECOV_TOKEN }}
env_vars: OS,NODE
file: ./coverage/codecov.json
eslint:
name: ESLint
runs-on: ubuntu-latest
if: ${{ github.event_name != 'schedule' }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: '*'
- run: npm ci
- run: npx eslint .
dprint:
name: dprint
runs-on: ubuntu-latest
if: ${{ github.event_name != 'schedule' }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: '*'
- run: npm ci
- run: npx dprint check
check-latest:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
name: Check latest on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: '*'
- run: npm ci
- run: npm pack
- run: npm install -g hereby
- run: |
set -exo pipefail
WORKSPACE=$PWD
cd $(mktemp -d)
npm init -y
npm install $WORKSPACE/*.tgz
cp $WORKSPACE/dist/__tests__/cli/__fixtures__/Herebyfile.mjs .
hereby --tasks
name: Verify that latest hereby can run local hereby
- run: |
set -exo pipefail
WORKSPACE=$PWD
cd $(mktemp -d)
npm init -y
npm install hereby
cp $WORKSPACE/dist/__tests__/cli/__fixtures__/Herebyfile.mjs .
node $WORKSPACE/bin/hereby.js --tasks
name: Verify that local hereby can run latest hereby
required:
runs-on: ubuntu-latest
if: ${{ always() }}
needs:
- test
- eslint
- dprint
- check-latest
steps:
- name: Check required jobs
run: |
results=(
"${{ needs.test.result }}"
"${{ github.event_name != 'schedule' && needs.eslint.result || 'success' }}"
"${{ github.event_name != 'schedule' && needs.dprint.result || 'success' }}"
"${{ needs.check-latest.result }}"
)
for result in "${results[@]}"; do
if [[ "$result" != "success" ]]; then
echo "One or more jobs failed"
exit 1
fi
done