eslint.yml -> js.yml
This commit is contained in:
parent
8ba46c52ec
commit
603224c13e
1 changed files with 0 additions and 0 deletions
33
.github/workflows/js.yml
vendored
Normal file
33
.github/workflows/js.yml
vendored
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
# https://docs.github.com/en/code-security/code-scanning/integrating-with-code-scanning/uploading-a-sarif-file-to-github#example-workflow-that-runs-the-eslint-analysis-tool
|
||||
|
||||
name: "ESLint analysis"
|
||||
|
||||
# Run workflow each time code is pushed to your repository and on a schedule.
|
||||
# The scheduled workflow runs every Wednesday at 15:45 UTC.
|
||||
on:
|
||||
push:
|
||||
schedule:
|
||||
- cron: '45 15 * * 3'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
# required for all workflows
|
||||
security-events: write
|
||||
# only required for workflows in private repositories
|
||||
actions: read
|
||||
contents: read
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Run npm install
|
||||
run: npm install
|
||||
# Runs the ESlint code analysis
|
||||
- name: Run ESLint
|
||||
# eslint exits 1 if it finds anything to report
|
||||
run: node_modules/.bin/eslint build docs lib script spec-main -f node_modules/@microsoft/eslint-formatter-sarif/sarif.js -o results.sarif || true
|
||||
# Uploads results.sarif to GitHub repository using the upload-sarif action
|
||||
- uses: github/codeql-action/upload-sarif@v3
|
||||
with:
|
||||
# Path to SARIF file relative to the root of the repository
|
||||
sarif_file: results.sarif
|
||||
Loading…
Add table
Add a link
Reference in a new issue