From acba0d0cb82dfdd522ca29d3e69dffe2e1eaed90 Mon Sep 17 00:00:00 2001 From: szymon Date: Fri, 25 Dec 2020 19:34:36 +0100 Subject: [PATCH] File names now end with minecraft minor version and should not contain patch id. --- build.gradle | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 2b9302d..610e8da 100644 --- a/build.gradle +++ b/build.gradle @@ -7,7 +7,7 @@ sourceCompatibility = JavaVersion.VERSION_1_8 targetCompatibility = JavaVersion.VERSION_1_8 archivesBaseName = project.archives_base_name -version = "${project.mod_version}-${project.minecraft_version}" +version = "${project.mod_version}-${getMcMinor(project.minecraft_version)}" group = project.maven_group minecraft { @@ -95,3 +95,9 @@ publishing { // mavenLocal() } } + +static def getMcMinor(ver) { + String[] arr = ((String)ver).split("\\."); + + return (String)(arr[0] + "." + arr[1]); +}