From 952a851690bdff2b5e75272c8a45b15e1ecf462b Mon Sep 17 00:00:00 2001 From: DStrand1 Date: Mon, 11 Dec 2023 00:53:18 +0000 Subject: [PATCH 1/2] update build script version to 1702244235 --- build.gradle | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/build.gradle b/build.gradle index 5e4447c6c45..29b2ba602bf 100644 --- a/build.gradle +++ b/build.gradle @@ -1,4 +1,4 @@ -//version: 1701739812 +//version: 1702244235 /* * DO NOT CHANGE THIS FILE! * Also, you may replace this file at any time if there is an update available. @@ -79,6 +79,7 @@ propertyDefaultIfUnset("curseForgeRelations", "") propertyDefaultIfUnsetWithEnvVar("releaseType", "release", "RELEASE_TYPE") propertyDefaultIfUnset("generateDefaultChangelog", false) propertyDefaultIfUnset("customMavenPublishUrl", "") +propertyDefaultIfUnset("mavenArtifactGroup", getDefaultArtifactGroup()) propertyDefaultIfUnset("enableModernJavaSyntax", false) propertyDefaultIfUnset("enableSpotless", false) propertyDefaultIfUnset("enableJUnit", false) @@ -984,8 +985,8 @@ if (customMavenPublishUrl) { } // providers is not available here, use System for getting env vars - groupId = System.getenv('ARTIFACT_GROUP_ID') ?: project.group - artifactId = System.getenv('ARTIFACT_ID') ?: project.name + groupId = System.getenv('ARTIFACT_GROUP_ID') ?: project.mavenArtifactGroup + artifactId = System.getenv('ARTIFACT_ID') ?: project.modArchivesBaseName version = System.getenv('RELEASE_VERSION') ?: publishedVersion } } @@ -1130,6 +1131,11 @@ tasks.register('faq') { // Helpers +def getDefaultArtifactGroup() { + def lastIndex = project.modGroup.lastIndexOf('.') + return lastIndex < 0 ? project.modGroup : project.modGroup.substring(0, lastIndex) +} + def getFile(String relativePath) { return new File(projectDir, relativePath) } From bf11b138e612f53c203d61698e773383e6db1476 Mon Sep 17 00:00:00 2001 From: alongstringofnumbers Date: Mon, 11 Dec 2023 16:48:30 -0700 Subject: [PATCH 2/2] gradle.properties update --- gradle.properties | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/gradle.properties b/gradle.properties index 2cc4c9a9e46..759702affde 100644 --- a/gradle.properties +++ b/gradle.properties @@ -52,6 +52,8 @@ accessTransformersFile = gregtech_at.cfg usesMixins = false # Specify the package that contains all of your Mixins. You may only place Mixins in this package or the build will fail! mixinsPackage = +# Automatically generates a mixin config json if enabled, with the name mixins.modid.json +generateMixinConfig=false # Specify the core mod entry class if you use a core mod. This class must implement IFMLLoadingPlugin! # Example value: coreModClass = asm.FMLPlugin + modGroup = com.myname.mymodid -> com.myname.mymodid.asm.FMLPlugin coreModClass = asm.GregTechLoadingPlugin @@ -75,6 +77,7 @@ includeWellKnownRepositories = true # Overrides the above setting to be always true, as these repositories are needed to fetch the mods includeCommonDevEnvMods = true + # If enabled, you may use 'shadowCompile' for dependencies. They will be integrated in your jar. It is your # responsibility check the licence and request permission for distribution, if required. usesShadowedDependencies = false @@ -120,6 +123,7 @@ curseForgeProjectId = curseForgeRelations = requiredDependency:codechicken-lib-1-8;requiredDependency:modularui;requiredDependency:mixin-booter;incompatible:gregtechce # This project's release type on CurseForge and/or Modrinth +# Alternatively this can be set with the 'RELEASE_TYPE' environment variable. # Allowed types: release, beta, alpha releaseType = beta @@ -129,6 +133,17 @@ generateDefaultChangelog = false # Prevent the source code from being published noPublishedSources = false +# Publish to a custom maven location. Follows a few rules: +# Group ID can be set with the 'ARTIFACT_GROUP_ID' environment variable, default to 'project.group' +# Artifact ID can be set with the 'ARTIFACT_ID' environment variable, default to 'project.name' +# Version can be set with the 'RELEASE_VERSION' environment variable, default to 'modVersion' +# For maven credentials: +# Username is set with the 'MAVEN_USER' environment variable, default to "NONE" +# Password is set with the 'MAVEN_PASSWORD' environment variable, default to "NONE" +customMavenPublishUrl= +# The group for maven artifacts. Defaults to the 'project.modGroup' until the last '.' (if any). +# So 'mymod' becomes 'mymod' and 'com.myname.mymodid' 'becomes com.myname' +mavenArtifactGroup= # Enable spotless checks # Enforces code formatting on your source code