Skip to content

[DEV-18547] Feature - Support ESLint v9 #7

[DEV-18547] Feature - Support ESLint v9

[DEV-18547] Feature - Support ESLint v9 #7

Workflow file for this run

name: ESLint Smoke Test
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/checkout@v4
- name: Setup environment
uses: prezly/setup-github-actions@v1
with:
pnpm: 9.7.0
node: 20
- name: Install dependencies
run: pnpm install
- name: Run ESLint
id: eslint
run: |
cd tests/react-ts
pnpm lint
lint_exit_code=$?
echo "The exit code of pnpm lint is: $lint_exit_code"
echo "lint_exit_code=$lint_exit_code" >> $GITHUB_ENV
continue-on-error: true # Allow failure but capture exit code
- name: Evaluate ESLint result
run: |
if [ "$lint_exit_code" -eq 0 ]; then
echo "ESLint passed unexpectedly. Marking this as a failure."
exit 1
else
echo "ESLint failed as expected. Marking this as a success."
exit 0
fi
env:
lint_exit_code: ${{ env.lint_exit_code }}