Put some stuff that was duplicated in gradle to the main gradle
This commit is contained in:
@@ -57,37 +57,9 @@ task copyCommonResources(type: Copy) {
|
||||
into file("build/resources/main")
|
||||
}
|
||||
|
||||
// Put stuff from gradle.properties into the mod info stuff
|
||||
def resourceTargets = ["META-INF/mods.toml"]
|
||||
def intoTargets = ["$buildDir/resources/main/"]
|
||||
def replaceProperties = [
|
||||
version: mod_version,
|
||||
mod_name: mod_name,
|
||||
authors: mod_authors,
|
||||
description: mod_description
|
||||
]
|
||||
|
||||
processResources {
|
||||
dependsOn(copyCoreResources)
|
||||
dependsOn(copyCommonResources)
|
||||
|
||||
inputs.properties replaceProperties
|
||||
replaceProperties.put 'project', project
|
||||
filesMatching(resourceTargets) {
|
||||
expand replaceProperties
|
||||
}
|
||||
|
||||
intoTargets.each { target ->
|
||||
if (file(target).exists()) {
|
||||
copy {
|
||||
from(sourceSets.main.resources) {
|
||||
include resourceTargets
|
||||
expand replaceProperties
|
||||
}
|
||||
into target
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
shadowJar {
|
||||
|
||||
@@ -9,14 +9,13 @@ issueTrackerURL="https://gitlab.com/jeseibel/minecraft-lod-mod/-/issues"
|
||||
modId="lod" #//mandatory
|
||||
version= "${version}" #//mandatory, gets the version number from jar populated by the build.gradle script
|
||||
displayName="${mod_name}" #//mandatory
|
||||
authors="${authors}"
|
||||
#//updateJSONURL="https://change.me.example.invalid/updates.json" # A URL to query for updates for this mod. See the JSON update specification https://mcforge.readthedocs.io/en/latest/gettingstarted/autoupdate/
|
||||
displayURL="https://www.curseforge.com/minecraft/mc-mods/lod-level-of-detail"
|
||||
displayURL="${homepage}"
|
||||
description= "${description}" #//mandatory. The description text for the mod
|
||||
logoFile="logo.png"
|
||||
catalogueImageIcon="icon.png"
|
||||
credits="Massive thanks to: Leonardo, Cola, Ran, and CoolGi. For their hard work to bring Distant Horizons to where it is today. - James"
|
||||
authors="${authors}"
|
||||
#//mandatory. The description text for the mod
|
||||
description= ''' ${description} '''
|
||||
#// if not set defaults to "false"
|
||||
clientSideOnly="true"
|
||||
#// if not set defaults to "BOTH"
|
||||
|
||||
Reference in New Issue
Block a user