-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
113 additions
and
2 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: Run diKTat (release) | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
diktat_check: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
# required for all workflows | ||
security-events: write | ||
|
||
steps: | ||
- name: This action is disabled until the release 2.0.0 | ||
run: | | ||
echo "This action is disabled until the release 2.0.0" | ||
# - uses: actions/checkout@v3 | ||
# - name: Set up JDK 11 | ||
# uses: actions/setup-java@v3 | ||
# with: | ||
# java-version: 11 | ||
# distribution: temurin | ||
# - uses: gradle/gradle-build-action@v2 | ||
# with: | ||
# gradle-version: wrapper | ||
# arguments: | | ||
# diktatCheck | ||
# mergeDiktatReports | ||
# -Pdiktat.githubActions=true | ||
# -Pdetekt.multiplatform.disabled=true | ||
# --build-cache | ||
# --continue | ||
# -PgprUser=${{ github.actor }} | ||
# -PgprKey=${{ secrets.GITHUB_TOKEN }} | ||
# - name: Upload SARIF report to Github | ||
# uses: github/codeql-action/upload-sarif@v2 | ||
# if: ${{ always() }} | ||
# with: | ||
# sarif_file: build/reports/diktat/diktat-merged.sarif | ||
# - name: Upload SARIF artifacts | ||
# uses: actions/upload-artifact@v3 | ||
# if: ${{ failure() }} | ||
# with: | ||
# name: sarif-reports | ||
# path: "**/build/reports/diktat" | ||
# retention-days: 1 |
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
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
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
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
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
26 changes: 26 additions & 0 deletions
26
.../main/kotlin/com/saveourtool/diktat/buildutils/diktat-convention-configuration.gradle.txt
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package org.cqfn.diktat.buildutils | ||
|
||
|
||
plugins { | ||
id("org.cqfn.diktat.diktat-gradle-plugin") | ||
} | ||
|
||
diktat { | ||
diktatConfigFile = rootProject.file("diktat-analysis.yml") | ||
githubActions = findProperty("diktat.githubActions")?.toString()?.toBoolean() ?: false | ||
inputs { | ||
// using `Project#path` here, because it must be unique in gradle's project hierarchy | ||
if (path == rootProject.path) { | ||
include("gradle/plugins/src/**/*.kt", "*.kts", "gradle/plugins/**/*.kts") | ||
exclude("gradle/plugins/build/**") | ||
} else { | ||
include("src/**/*.kt", "**/*.kts") | ||
exclude( | ||
"src/test/**/*.kt", | ||
"src/test/**/*.kts", | ||
"src/*Test/**/*.kt", | ||
"build/**/*.kts", | ||
) | ||
} | ||
} | ||
} |