ci(java): attempt to configure java library correctly

This commit is contained in:
zaaarf 2024-10-15 20:32:39 +02:00
parent 21b76767bd
commit b452cb822f
No known key found for this signature in database
GPG key ID: C91CFF9E2262BBA1
2 changed files with 10 additions and 21 deletions

View file

@ -70,14 +70,13 @@ configurations {
} }
} }
artifacts {
windowsJar(windowsJar)
macosJar(macosJar)
linuxJar(linuxJar)
}
java { java {
sourceCompatibility = targetCompatibility = JavaVersion.VERSION_11 sourceCompatibility = targetCompatibility = JavaVersion.VERSION_11
artifacts {
windowsJar(windowsJar)
macosJar(macosJar)
linuxJar(linuxJar)
}
} }
repositories { repositories {
@ -117,24 +116,14 @@ tasks.register('nativeBuild', Jar) {
} }
} }
publishing {
publications {
mavenJava(MavenPublication) {
artifact jar
//artifact sourcesJar
//artifact javadocJar
artifact windowsJar
artifact linuxJar
artifact macosJar
}
}
}
import com.vanniktech.maven.publish.SonatypeHost import com.vanniktech.maven.publish.SonatypeHost
import com.vanniktech.maven.publish.JavaLibrary
import com.vanniktech.maven.publish.JavadocJar
mavenPublishing { mavenPublishing {
publishToMavenCentral(SonatypeHost.CENTRAL_PORTAL) //, true) // TODO re-enable autopublish! publishToMavenCentral(SonatypeHost.CENTRAL_PORTAL) //, true) // TODO re-enable autopublish!
signAllPublications() signAllPublications()
coordinates(project.group, rootProject.name, project.version) coordinates(project.group, rootProject.name, project.version)
configure(new JavaLibrary(new JavadocJar.Javadoc(), true))
pom { pom {
name = rootProject.name name = rootProject.name

View file

@ -2,8 +2,8 @@ package mp.code.exceptions;
/** /**
* An exception that may occur when a {@link mp.code.BufferController} or * An exception that may occur when a {@link mp.code.BufferController} or
* a {@link mp.code.CursorController} perform an illegal operation. * a {@link mp.code.CursorController} or {@link mp.code.Workspace} (in the
* It may also occur as a result of {@link mp.code.Workspace#event()}. * receiver part) perform an illegal operation.
*/ */
public abstract class ControllerException extends Exception { public abstract class ControllerException extends Exception {