Skip to content

Commit 9a28958

Browse files
updated codacy-analysis cli action
1 parent 4359901 commit 9a28958

File tree

1 file changed

+23
-4
lines changed

1 file changed

+23
-4
lines changed
Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,33 @@
1-
name: Codacy Analysis CLI
1+
name: Codacy Security Scan
22

3-
on: ["push"]
3+
on:
4+
push:
5+
branches: [ "master", "main" ]
6+
pull_request:
7+
branches: [ "master", "main" ]
48

59
jobs:
6-
codacy-analysis-cli:
7-
name: Codacy Analysis CLI
10+
codacy-security-scan:
11+
name: Codacy Security Scan
812
runs-on: ubuntu-latest
913
steps:
1014
- name: Checkout code
1115
uses: actions/checkout@master
1216

1317
- name: Run Codacy Analysis CLI
1418
uses: codacy/codacy-analysis-cli-action@master
19+
with:
20+
output: results.sarif
21+
format: sarif
22+
# Adjust severity of non-security issues
23+
gh-code-scanning-compat: true
24+
# Force 0 exit code to allow SARIF file generation
25+
# This will handover control about PR rejection to the GitHub side
26+
max-allowed-issues: 2147483647
27+
28+
# Upload the SARIF file generated in the previous step
29+
- name: Upload SARIF results file
30+
uses: github/codeql-action/upload-sarif@master
31+
with:
32+
sarif_file: results.sarif
33+

0 commit comments

Comments
 (0)