-
Notifications
You must be signed in to change notification settings - Fork 15
/
build.gradle.kts
53 lines (46 loc) · 1.42 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
import com.github.benmanes.gradle.versions.updates.DependencyUpdatesTask
import org.jlleitschuh.gradle.ktlint.reporter.ReporterType
buildscript {
repositories {
mavenCentral()
google()
}
dependencies {
classpath("com.android.tools.build:gradle:7.4.2")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${Versions.KOTLIN}")
classpath("io.realm:realm-gradle-plugin:7.0.8")
classpath("com.google.gms:google-services:4.3.14")
classpath("com.google.firebase:firebase-crashlytics-gradle:2.9.2")
}
}
plugins {
id("com.github.ben-manes.versions") version "0.39.0"
// Make sure to update this in `buildSrc/build.gradle.kts` as well
id("org.jlleitschuh.gradle.ktlint") version "10.2.0"
}
allprojects {
repositories {
jcenter()
mavenCentral()
google()
}
}
ktlint {
version.set("0.42.1") // Make sure to update this in `buildSrc/build.gradle.kts` as well
android.set(true)
ignoreFailures.set(true)
reporters {
reporter(ReporterType.CHECKSTYLE)
}
}
tasks.withType<DependencyUpdatesTask> {
gradleReleaseChannel = "current"
rejectVersionIf {
listOf(
"alpha", "beta", "rc", "cr", "m", "release", "preview", "b", "ea", "eap", "patch"
).any { qualifier ->
val regex = "(?i).*[.-]$qualifier[.\\d-+]*".toRegex()
regex.matches(candidate.version)
}
}
}