tasko/.github/workflows/eslint.yml

40 lines
1 KiB
YAML
Raw Normal View History

2024-03-02 02:48:39 +00:00
name: ESLint
on:
push:
2024-03-15 21:03:28 +00:00
branches: ['main']
2024-03-02 02:48:39 +00:00
pull_request:
# The branches below must be a subset of the branches above
2024-03-15 21:03:28 +00:00
branches: ['main']
2024-03-02 02:48:39 +00:00
schedule:
- cron: '25 21 * * 1'
jobs:
eslint:
name: Run eslint scanning
runs-on: ubuntu-latest
permissions:
contents: read
security-events: write
actions: read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install Dependencies
run: yarn install
2024-03-02 02:48:39 +00:00
- name: Run ESLint
run: yarn dlx next lint
2024-03-02 02:51:44 +00:00
--config .eslintrc.json
2024-03-02 02:48:39 +00:00
--ext .js,.jsx,.ts,.tsx
--format @microsoft/eslint-formatter-sarif
--output-file eslint-results.sarif
continue-on-error: true
- name: Upload analysis results to GitHub
2024-03-02 02:51:44 +00:00
uses: github/codeql-action/upload-sarif@v3
2024-03-02 02:48:39 +00:00
with:
sarif_file: eslint-results.sarif
2024-03-15 21:03:28 +00:00
wait-for-processing: true