revanced-patches-tasker/build.gradle.kts

60 lines
1.6 KiB
Plaintext
Raw Normal View History

2022-03-21 15:19:51 +00:00
plugins {
kotlin("jvm") version "1.6.21"
java
2022-03-21 15:19:51 +00:00
`maven-publish`
}
group = "app.revanced"
2022-03-21 15:19:51 +00:00
repositories {
mavenCentral()
mavenLocal()
2022-03-21 15:19:51 +00:00
maven {
2022-05-06 23:23:58 +00:00
url = uri("https://maven.pkg.github.com/revanced/revanced-patcher") // note the "r"!
2022-03-21 15:19:51 +00:00
credentials {
// DO NOT set these variables in the project's gradle.properties.
// Instead, you should set them in:
// Windows: %homepath%\.gradle\gradle.properties
// Linux: ~/.gradle/gradle.properties
username = project.findProperty("gpr.user") as String? ?: System.getenv("GITHUB_ACTOR") // DO NOT CHANGE!
password = project.findProperty("gpr.key") as String? ?: System.getenv("GITHUB_TOKEN") // DO NOT CHANGE!
2022-03-21 15:19:51 +00:00
}
}
}
dependencies {
implementation("org.jetbrains.kotlin:kotlin-stdlib:1.6.21")
2022-03-21 15:19:51 +00:00
2022-06-05 06:14:58 +00:00
implementation("app.revanced:revanced-patcher:1.0.0")
implementation("org.jetbrains.kotlin:kotlin-reflect:1.6.21")
}
java {
withSourcesJar()
withJavadocJar()
}
val isGitHubCI = System.getenv("GITHUB_ACTOR") != null
publishing {
repositories {
if (isGitHubCI) {
maven {
name = "GitHubPackages"
2022-05-06 23:23:58 +00:00
url = uri("https://maven.pkg.github.com/revanced/revanced-patches") // note the "s"!
credentials {
username = System.getenv("GITHUB_ACTOR")
password = System.getenv("GITHUB_TOKEN")
}
}
} else {
mavenLocal()
}
}
publications {
register<MavenPublication>("gpr") {
from(components["java"])
}
}
2022-05-06 23:23:58 +00:00
}