generated from segment-integrations/analytics-kotlin-destination-template
-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle.kts
49 lines (41 loc) · 1.06 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
val GROUP: String by project
val VERSION_NAME: String by project
group = GROUP
version = getVersionName()
plugins {
// Apply the org.jetbrains.kotlin.jvm Plugin to add support for Kotlin.
id("org.jetbrains.kotlin.jvm") version "1.8.0"
// Apply the java-library plugin for API and implementation separation.
`java-library`
id("io.github.gradle-nexus.publish-plugin") version "1.1.0"
}
buildscript {
repositories {
// Use JCenter for resolving dependencies.
mavenCentral()
google()
gradlePluginPortal()
}
dependencies {
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.0")
classpath("org.jetbrains.kotlin:kotlin-serialization:1.6.0")
classpath("com.android.tools.build:gradle:7.0.4")
}
}
allprojects {
repositories {
mavenCentral()
google()
gradlePluginPortal()
}
}
nexusPublishing {
repositories {
sonatype()
}
}
fun getVersionName() =
if (hasProperty("release"))
VERSION_NAME
else
"$VERSION_NAME-SNAPSHOT"