Final fix-ups

- Revert mods.toml version to ${file.jarVersion}
- Fix license not being added to built jars
- Rename LICENCE.md to LICENSE.md
This commit is contained in:
PepperCode1 2022-07-15 19:29:42 -07:00
parent 2a715dfd5d
commit 2323e770d2
3 changed files with 5 additions and 12 deletions

View File

@ -124,19 +124,11 @@ dependencies {
} }
} }
processResources {
inputs.property 'version', mod_version
filesMatching('META-INF/mods.toml') {
expand 'version': mod_version
}
}
mixin { mixin {
add sourceSets.main, 'flywheel.refmap.json' add sourceSets.main, 'flywheel.refmap.json'
} }
// Fix for SpongePowered/MixinGradle#38 // Workaround for SpongePowered/MixinGradle#38
afterEvaluate { afterEvaluate {
tasks.configureReobfTaskForReobfJar.mustRunAfter(tasks.compileJava) tasks.configureReobfTaskForReobfJar.mustRunAfter(tasks.compileJava)
} }
@ -172,8 +164,8 @@ java {
} }
void addLicense(jarTask) { void addLicense(jarTask) {
jarTask.from('LICENSE') { jarTask.from('LICENSE.md') {
rename { "${it}_${project.archivesBaseName}" } rename '(.*)\\.(.*)', '$1_' + archivesBaseName + '.$2'
} }
} }

View File

@ -5,7 +5,8 @@ license = "MIT"
[[mods]] [[mods]]
modId = "flywheel" modId = "flywheel"
version = "${version}" # The Implementation-Version property in the jar's MANIFEST.MF file will be used as the mod version at runtime
version = "${file.jarVersion}"
displayName = "Flywheel" displayName = "Flywheel"
logoFile = "logo.png" logoFile = "logo.png"
displayURL = "https://www.curseforge.com/minecraft/mc-mods/flywheel" displayURL = "https://www.curseforge.com/minecraft/mc-mods/flywheel"