Skip to content

Commit

Permalink
Upload ESLint results to code scanning
Browse files Browse the repository at this point in the history
  • Loading branch information
tspascoal authored Nov 2, 2024
1 parent fad4f57 commit 4925f63
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 2 deletions.
8 changes: 7 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,13 @@ jobs:
- name: Run Linting
run: npm run lint

- name: Upload eslint results code scanning
uses: github/codeql-action/upload-sarif@v3
if: always() && github.actor != 'dependabot[bot]'
with:
category: eslint
sarif_file: eslint.sarif

- name: Run tests Linux
run: xvfb-run -a npm test
if: runner.os == 'Linux'
Expand All @@ -62,6 +69,5 @@ jobs:
with:
name: extension
path: '*.vsix'
name: Release Extension


1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ node_modules
.vscode-test/
*.vsix
coverage/
*.sarif
34 changes: 34 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,11 @@
"watch-tests": "tsc -p . -w --outDir out",
"pretest": "npm run compile-tests && npm run compile && npm run lint",
"check-types": "tsc --noEmit",
"lint": "eslint src --ext ts",
"lint": "eslint src --ext ts -f @microsoft/eslint-formatter-sarif -o eslint.sarif",
"test": "vscode-test"
},
"devDependencies": {
"@microsoft/eslint-formatter-sarif": "^3.1.0",
"@types/mocha": "^10.0.7",
"@types/node": "20.x",
"@types/sinon": "^17.0.3",
Expand Down

0 comments on commit 4925f63

Please sign in to comment.