-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
72 lines (62 loc) · 1.78 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
import org.cadixdev.gradle.licenser.LicenseExtension
plugins {
`java-library`
`maven-publish`
id("net.researchgate.release") version "2.8.1"
id("org.cadixdev.licenser") version "0.5.1"
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(11))
}
withSourcesJar()
withJavadocJar()
}
repositories {
mavenCentral()
maven {
name = "WPI"
url = uri("https://frcmaven.wpi.edu/artifactory/release")
}
}
dependencies {
api("edu.wpi.first.hal:hal-java:2020.3.2")
val autoValueVersion = "1.7.4"
compileOnly("com.google.auto.value:auto-value-annotations:$autoValueVersion")
annotationProcessor("com.google.auto.value:auto-value:$autoValueVersion")
compileOnly("com.techshroom", "jsr305-plus", "0.0.1")
}
configure<LicenseExtension> {
header = rootProject.file("HEADER.txt")
(this as ExtensionAware).extra.apply {
set("name", rootProject.name)
for (key in listOf("organization", "url")) {
set(key, rootProject.property(key))
}
}
}
tasks.processResources {
from("LICENSE-vl53l1x.txt")
from("LICENSE-vl53l0x.txt")
from("LICENSE-vl6180x.txt")
from("LICENSE.txt")
}
release {
tagTemplate = "v\${version}"
}
publishing {
publications {
register<MavenPublication>("library") {
from(components["java"])
}
}
repositories {
maven {
val releasesRepoUrl = "https://maven.octyl.net/repository/armabot-releases"
val snapshotsRepoUrl = "https://maven.octyl.net/repository/armabot-snapshots"
name = "octylNet"
url = uri(if (version.toString().endsWith("SNAPSHOT")) snapshotsRepoUrl else releasesRepoUrl)
credentials(PasswordCredentials::class)
}
}
}