diff --git a/.gitea/workflows/detekt.yml b/.gitea/workflows/detekt.yml index e6c947f..5f7c1c5 100644 --- a/.gitea/workflows/detekt.yml +++ b/.gitea/workflows/detekt.yml @@ -1,40 +1,22 @@ -name: Detekt +steps: + - name: Checkout code + uses: actions/checkout@v4 -on: - push: - branches: [main, master] - pull_request: - branches: [main, master] + - name: Set up JDK 17 + uses: actions/setup-java@v4 + with: + java-version: '17' + distribution: 'temurin' -jobs: - detekt: - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 + - name: Download Detekt CLI # ← должен быть этот шаг + run: | + curl -sSLO https://github.com/detekt/detekt/releases/download/v1.23.6/detekt-cli-1.23.6-all.jar - - name: Set up JDK 17 - uses: actions/setup-java@v4 - with: - java-version: '17' - distribution: 'temurin' + - name: Run Detekt # ← и этот + run: | + java -jar detekt-cli-1.23.6-all.jar --input . --report txt:detekt-report.txt + continue-on-error: true - - name: Download Detekt CLI - run: | - curl -sSLO https://github.com/detekt/detekt/releases/download/v1.23.6/detekt-cli-1.23.6-all.jar - - - name: Run Detekt - run: | - java -jar detekt-cli-1.23.6-all.jar --input . --report txt:detekt-report.txt - continue-on-error: true - - - name: Show Detekt report - run: cat detekt-report.txt - if: always() - - - name: Upload Detekt report - uses: actions/upload-artifact@v4 - if: always() - with: - name: detekt-report - path: detekt-report.txt \ No newline at end of file + - name: Show Detekt report # ← и этот для отчёта + run: cat detekt-report.txt + if: always() \ No newline at end of file