better ux #1244
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "CodeQL and ESLint Analysis" | |
on: | |
push: | |
branches: [ "master", "Staging" ] | |
pull_request: | |
branches: [ "master", "Staging" ] | |
schedule: | |
- cron: '22 17 * * 5' | |
jobs: | |
analyze: | |
name: Analyze | |
runs-on: ubuntu-latest | |
timeout-minutes: 360 | |
permissions: | |
actions: read | |
contents: read | |
security-events: write | |
strategy: | |
fail-fast: false | |
matrix: | |
language: [ 'javascript', 'typescript' ] | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
# Initializes the CodeQL tools for scanning. | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v3 | |
with: | |
languages: ${{ matrix.language }} | |
- name: Autobuild | |
uses: github/codeql-action/autobuild@v3 | |
- name: Perform CodeQL Analysis | |
uses: github/codeql-action/analyze@v3 | |
with: | |
category: "/language:${{ matrix.language }}" | |
# Set up Node.js | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '20' | |
# Install dependencies | |
- name: Install dependencies | |
run: npm install | |
# Run ESLint | |
- name: Run ESLint | |
run: npx eslint '**/*.{js,ts,tsx}' |