forked from yuriykulikov/AlarmClock
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
53 lines (48 loc) · 1.14 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
buildscript {
repositories { google() }
dependencies { dependencies { classpath("com.android.tools.build:gradle:7.3.1") } }
}
plugins {
jacoco
id("com.diffplug.spotless") version "6.18.0"
val kotlin = "1.9.10"
kotlin("plugin.serialization") version kotlin apply false
kotlin("android") version kotlin apply false
}
allprojects {
repositories {
mavenCentral()
google()
}
}
spotless {
kotlin {
target("build.gradle.kts")
ktfmt()
lineEndings = com.diffplug.spotless.LineEnding.UNIX
}
}
/** Applies spotless to app projects */
subprojects {
// afterEvaluate is required for android projects
afterEvaluate {
apply(plugin = "com.diffplug.spotless")
spotless {
kotlin {
target("build.gradle.kts", "**/*.kt")
targetExclude("$buildDir/**/*.kt")
targetExclude("**/test/resources/**/*.kt")
ktfmt()
lineEndings = com.diffplug.spotless.LineEnding.UNIX
}
}
spotless {
java {
target("**/*.java")
targetExclude("$buildDir/**/*.java")
googleJavaFormat()
lineEndings = com.diffplug.spotless.LineEnding.UNIX
}
}
}
}