Skip to content

fix: add iac ignore button [IDE-683] #2201

fix: add iac ignore button [IDE-683]

fix: add iac ignore button [IDE-683] #2201

Workflow file for this run

name: Code Scanning - Action
on:
push:
branches: [ master ]
pull_request:
jobs:
detekt:
runs-on: ubuntu-latest
steps:
- name: Fetch Sources
uses: actions/checkout@v4
- uses: actions/setup-java@v4
name: Setup Java
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Setup Gradle Cache
uses: actions/cache@v4
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
restore-keys: ${{ runner.os }}-gradle
- name: Run detekt Gradle task
run: ./gradlew detekt
continue-on-error: true
# modifies the SARIF output produced by Detekt so that absolute URIs are relative
- name: Make artifact location URIs relative
if: always()
run: |
echo "$(
jq \
--arg github_workspace ${{ github.workspace }} \
'. | ( .runs[].results[].locations[].physicalLocation.artifactLocation.uri |= if test($github_workspace) then .[($github_workspace | length | . + 1):] else . end )' \
build/detekt.sarif
)" > build/detekt.sarif
- name: Upload SARIF to GitHub
uses: github/codeql-action/upload-sarif@v3
if: success()
with:
sarif_file: build/detekt.sarif