Version 0.28 Beta 13 #144
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run detekt on push | |
on: | |
push: | |
branches: | |
- "beta" | |
paths-ignore: | |
- ".gitignore" | |
jobs: | |
detekt: | |
name: Run detekt | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
steps: | |
- name: Checkout PR code | |
uses: actions/checkout@v4 | |
- uses: ./.github/actions/setup-normal-workspace | |
- name: Run detekt main (w/ typing analysis) | |
run: | | |
./gradlew detektMain --stacktrace | |
- name: Check if SARIF file exists | |
id: check_sarif | |
run: | | |
if [ -f "versions/1.8.9/build/reports/detekt/main.sarif" ]; then | |
echo "exists=true" >> $GITHUB_OUTPUT | |
else | |
echo "exists=false" >> $GITHUB_OUTPUT | |
fi | |
- name: Annotate detekt failures | |
if: ${{ !cancelled() && steps.check_sarif.outputs.exists == 'true' }} | |
run: | | |
chmod +x .github/scripts/process_detekt_sarif.sh | |
./.github/scripts/process_detekt_sarif.sh versions/1.8.9/build/reports/detekt/main.sarif |