diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/android/app/build.gradle.kts | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/android/app/build.gradle.kts b/src/android/app/build.gradle.kts index cb5f8b60c..7ae538cf9 100644 --- a/src/android/app/build.gradle.kts +++ b/src/android/app/build.gradle.kts | |||
| @@ -2,7 +2,9 @@ | |||
| 2 | // SPDX-License-Identifier: GPL-3.0-or-later | 2 | // SPDX-License-Identifier: GPL-3.0-or-later |
| 3 | 3 | ||
| 4 | import android.annotation.SuppressLint | 4 | import android.annotation.SuppressLint |
| 5 | import kotlin.collections.setOf | ||
| 5 | import org.jetbrains.kotlin.konan.properties.Properties | 6 | import org.jetbrains.kotlin.konan.properties.Properties |
| 7 | import org.jlleitschuh.gradle.ktlint.reporter.ReporterType | ||
| 6 | 8 | ||
| 7 | plugins { | 9 | plugins { |
| 8 | id("com.android.application") | 10 | id("com.android.application") |
| @@ -10,6 +12,7 @@ plugins { | |||
| 10 | id("kotlin-parcelize") | 12 | id("kotlin-parcelize") |
| 11 | kotlin("plugin.serialization") version "1.8.21" | 13 | kotlin("plugin.serialization") version "1.8.21" |
| 12 | id("androidx.navigation.safeargs.kotlin") | 14 | id("androidx.navigation.safeargs.kotlin") |
| 15 | id("org.jlleitschuh.gradle.ktlint") version "11.4.0" | ||
| 13 | } | 16 | } |
| 14 | 17 | ||
| 15 | /** | 18 | /** |
| @@ -157,6 +160,23 @@ android { | |||
| 157 | } | 160 | } |
| 158 | } | 161 | } |
| 159 | 162 | ||
| 163 | tasks.getByPath("preBuild").dependsOn("ktlintCheck") | ||
| 164 | |||
| 165 | ktlint { | ||
| 166 | version.set("0.47.0") | ||
| 167 | android.set(true) | ||
| 168 | ignoreFailures.set(false) | ||
| 169 | disabledRules.set( | ||
| 170 | setOf( | ||
| 171 | "no-wildcard-imports", | ||
| 172 | "package-name" | ||
| 173 | ) | ||
| 174 | ) | ||
| 175 | reporters { | ||
| 176 | reporter(ReporterType.CHECKSTYLE) | ||
| 177 | } | ||
| 178 | } | ||
| 179 | |||
| 160 | dependencies { | 180 | dependencies { |
| 161 | implementation("androidx.core:core-ktx:1.10.1") | 181 | implementation("androidx.core:core-ktx:1.10.1") |
| 162 | implementation("androidx.appcompat:appcompat:1.6.1") | 182 | implementation("androidx.appcompat:appcompat:1.6.1") |