-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathbuild.gradle
73 lines (67 loc) · 2.52 KB
/
build.gradle
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
ext{
android_gradle_plugin_version = '4.1.2'
// java.lang.NoSuchMethodError: No interface method startReplaceableGroup(ILjava/lang/String;)
// V in class Landroidx/compose/runtime/Composer;
// kotlin_version = "1.5.10"
kotlin_version = "1.4.32"
coroutines_version = '1.4.3'
compose_version = '1.0.0-beta08'
compose_activity_version = '1.3.0-beta01'
compose_appcompat_version = '1.3.0'
compose_constraintlayout_version = '1.0.0-alpha07'
compose_navigation_version = '2.4.0-alpha02'
compose_lifecycle_version = '1.0.0-alpha06'
compose_accompanist_version = "0.11.1"
compose_utils_chrisbanes_coil = "0.6.2"
compose_utils_coil = "1.2.2"
paging_compose_version = "1.0.0-alpha10"
}
repositories {
google()
jcenter()
// maven{ url 'http://maven.aliyun.com/nexus/content/groups/public/'}
}
dependencies {
classpath "com.android.tools.build:gradle:$android_gradle_plugin_version"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
plugins {
id 'com.diffplug.spotless' version '5.7.0'
}
allprojects {
repositories {
google()
jcenter()
// maven{ url 'http://maven.aliyun.com/nexus/content/groups/public/'}
}
apply plugin: 'com.diffplug.spotless'
spotless {
kotlin {
target '**/*.kt'
targetExclude("$buildDir/**/*.kt")
targetExclude('bin/**/*.kt')
ktlint("0.40.0")
// licenseHeaderFile rootProject.file('spotless/copyright.kt')
}
}
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all {
kotlinOptions {
jvmTarget = JavaVersion.VERSION_1_8.toString()
freeCompilerArgs += ["-Xskip-prerelease-check", "-progressive" ]
freeCompilerArgs += "-Xopt-in=kotlin.Experimental"
freeCompilerArgs += "-Xopt-in=kotlin.RequiresOptIn"
freeCompilerArgs += "-Xopt-in=kotlinx.coroutines.ExperimentalCoroutinesApi"
freeCompilerArgs += "-Xopt-in=kotlinx.coroutines.FlowPreview"
useIR = true
allWarningsAsErrors = false
}
}
}
//task clean(type: Delete) {
// delete rootProject.buildDir
//}