-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
71 lines (60 loc) · 1.48 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
plugins {
`kotlin-dsl`
kotlin("plugin.serialization") version "1.5.31"
`maven-publish`
}
group = "gay.pizza.foundation"
version = "0.1.0-SNAPSHOT"
repositories {
gradlePluginPortal()
}
dependencies {
implementation("org.jetbrains.kotlinx", "kotlinx-serialization-json", "1.3.3")
testImplementation(kotlin("test"))
}
tasks.test {
useJUnitPlatform()
}
java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
tasks.compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
gradlePlugin {
plugins {
create(name) {
id = "${group}.${name}"
implementationClass = "${id}.ResourcesGeneratorPlugin"
}
}
}
publishing {
repositories {
mavenLocal()
val githubPackagesToken = System.getenv("GITHUB_TOKEN")
?: project.findProperty("github.token") as String?
val gitlabPackagesToken = System.getenv("GITLAB_TOKEN")
?: project.findProperty("gitlab.com.accessToken") as String?
maven {
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/gaypizzaspecifications/drywall")
credentials {
username = project.findProperty("github.username") as String? ?: "gaypizzaspecifications"
password = githubPackagesToken
}
}
maven {
name = "GitLab"
url = uri("https://gitlab.com/api/v4/projects/47347654/packages/maven")
credentials(HttpHeaderCredentials::class.java) {
name = "Private-Token"
value = gitlabPackagesToken
}
authentication {
create<HttpHeaderAuthentication>("header")
}
}
}
}