You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
HuskSync/api/build.gradle

47 lines
1.2 KiB
Groovy

plugins {
id 'java-library'
id 'maven-publish'
}
dependencies {
implementation project(':common')
compileOnly 'org.spigotmc:spigot-api:1.16.5-R0.1-SNAPSHOT'
compileOnly 'org.jetbrains:annotations:22.0.0'
}
repositories {
mavenCentral()
maven { url 'https://hub.spigotmc.org/nexus/content/repositories/snapshots/' }
}
afterEvaluate {
publishing {
publications {
maven(MavenPublication) {
groupId = "${rootProject.group}.${rootProject.name.toLowerCase()}"
artifactId = project.name
from components.java
artifact javadocsJar
}
}
repositories {
mavenLocal()
}
}
}
task javadocs(type: Javadoc) {
options.addStringOption('Xdoclint:none', '-quiet')
source = project(':common').sourceSets.main.allJava
source += project(':api').sourceSets.main.allJava
classpath = files(project(':common').sourceSets.main.compileClasspath)
classpath += files(project(':api').sourceSets.main.compileClasspath)
destinationDir = file("${buildDir}/docs/javadoc")
}
task javadocsJar(type: Jar, dependsOn: javadocs) {
archiveClassifier.set 'javadoc'
from javadocs.destinationDir
}