-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle.kts
More file actions
72 lines (61 loc) · 2.21 KB
/
Copy pathbuild.gradle.kts
File metadata and controls
72 lines (61 loc) · 2.21 KB
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
import com.android.build.gradle.BaseExtension
buildscript {
repositories {
google()
mavenCentral()
maven("https://jitpack.io")
}
dependencies {
classpath("com.android.tools.build:gradle:8.2.2")
// Pinned commit instead of the -SNAPSHOT the template ships with,
// since -SNAPSHOT no longer resolves on JitPack.
classpath("com.github.recloudstream:gradle:81b1d424d2")
// Matches the Kotlin version CloudStream's current stubs expect.
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:2.3.0")
}
}
allprojects {
repositories {
google()
mavenCentral()
maven("https://jitpack.io")
}
}
fun Project.cloudstream(configuration: com.lagradost.cloudstream3.gradle.CloudstreamExtension.() -> Unit) =
extensions.getByName<com.lagradost.cloudstream3.gradle.CloudstreamExtension>("cloudstream").configuration()
fun Project.android(configuration: BaseExtension.() -> Unit) =
extensions.getByName<BaseExtension>("android").configuration()
subprojects {
apply(plugin = "com.android.library")
apply(plugin = "kotlin-android")
apply(plugin = "com.lagradost.cloudstream3.gradle")
cloudstream {
// Auto-fills from the GitHub repo this Action runs in — no edit needed.
setRepo(System.getenv("GITHUB_REPOSITORY") ?: "")
}
android {
compileSdkVersion(33)
defaultConfig {
minSdk = 21
targetSdk = 33
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
}
dependencies {
val implementation by configurations
val cloudstream by configurations
cloudstream("com.lagradost:cloudstream3:pre-release")
implementation(kotlin("stdlib"))
implementation("com.github.Blatzar:NiceHttp:0.4.11")
implementation("org.jsoup:jsoup:1.18.3")
implementation("com.fasterxml.jackson.module:jackson-module-kotlin:2.13.1")
}
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
compilerOptions {
jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_1_8)
}
}
}