Skip to content

Commit 512d808

Browse files
committed
chore(ci): update Codacy Security Scan workflow
1 parent f42247c commit 512d808

File tree

1 file changed

+7
-13
lines changed

1 file changed

+7
-13
lines changed

.github/workflows/codacy.yml

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,33 +17,27 @@ on:
1717
schedule:
1818
- cron: '0 21 * * 5' # Runs at 21:00, only on Friday
1919

20-
permissions:
21-
contents: read
22-
2320
jobs:
2421
codacy-security-scan:
25-
permissions:
26-
contents: read
27-
security-events: write
28-
actions: read
2922
name: Codacy Security Scan
3023
runs-on: ubuntu-latest
3124
steps:
3225
- name: Checkout code
33-
uses: actions/checkout@v4
34-
# Execute Codacy Analysis CLI and generate a SARIF output with the security
35-
# issues identified during the analysis
26+
uses: actions/checkout@main
27+
3628
- name: Run Codacy Analysis CLI
3729
uses: codacy/codacy-analysis-cli-action@master
3830
with:
39-
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
40-
verbose: true
4131
output: results.sarif
4232
format: sarif
33+
# Adjust severity of non-security issues
4334
gh-code-scanning-compat: true
35+
# Force 0 exit code to allow SARIF file generation
36+
# This will hand over control about PR rejection to the GitHub side
4437
max-allowed-issues: 2147483647
38+
4539
# Upload the SARIF file generated in the previous step
4640
- name: Upload SARIF results file
47-
uses: github/codeql-action/upload-sarif@v3
41+
uses: github/codeql-action/upload-sarif@main
4842
with:
4943
sarif_file: results.sarif

0 commit comments

Comments
 (0)