From 411bdb0d53e9c36028e4baae0a9eabcf74769739 Mon Sep 17 00:00:00 2001 From: q1zZ Date: Wed, 14 Feb 2024 23:23:15 +0100 Subject: [PATCH] Fix maven publishing in build.gradle --- build.gradle | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/build.gradle b/build.gradle index 0f08b65..d4ad3a0 100644 --- a/build.gradle +++ b/build.gradle @@ -1,13 +1,31 @@ -plugins { - id 'java' - id 'maven-publish' +allprojects { + group 'me.q1zz.spaceis.sdk' + version '0.2' } -allprojects { +subprojects { + + apply plugin: 'java' + apply plugin: 'maven-publish' + + sourceCompatibility = JavaVersion.VERSION_17 + targetCompatibility = JavaVersion.VERSION_17 java { - sourceCompatibility = JavaVersion.VERSION_17 - targetCompatibility = JavaVersion.VERSION_17 + withSourcesJar() + withJavadocJar() } -} \ No newline at end of file + publishing { + publications { + maven(MavenPublication) { + groupId project.group + artifactId project.name + version project.version + from components.java + } + } + } + +} +