plugins { `java-library` `maven-publish` id("jf.umldoc") } version = rootProject.version repositories { mavenCentral() maven("https://maven.frohnmeyer-wds.de/artifacts/") } dependencies { compileOnly("org.jetbrains:annotations:23.0.0") testImplementation("org.junit.jupiter:junit-jupiter-api:5.9.0") testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.9.0") } tasks.named("test") { useJUnitPlatform() } java { withSourcesJar() } publishing { repositories { mavenLocal() if (project.hasProperty("maven")) { maven { url = uri(project.property("maven").toString()) name = "dynamic" credentials(PasswordCredentials::class) { username = System.getenv()["MAVEN_NAME"] password = System.getenv()["MAVEN_TOKEN"] } authentication { create("basic") } } } } }