mod information are inconsistent and outdated
LemADEC opened this issue ยท 0 comments
As of 1.12.2-4.0.1.0_1.12_cc3a5aa:
-
mcmod.info refers to Minecraft 1.10.2 while it's for 1.12.2, here:
https://github.com/nekosune/modularforcefieldsystem/blob/1.12/src/main/resources/mcmod.info#L7 -
mcmod.info reports mod version 3.0.2 while the filename suggests 4.0.1
-
Mod metadata reports version 3.0.1 while the filename suggests 4.0.1, here:
https://github.com/nekosune/modularforcefieldsystem/blob/1.12/src/main/java/com/nekokittygames/mffs/common/ModularForceFieldSystem.java#L64
You can use gradle to replace your version tags and keep those in sync.
For example to update your @version@
tag in java sources:
minecraft {
...
// replacing
replace "@version@", project.version
replaceIn "ModularForceFieldSystem.java"
}
For example to expand version references in mcmod.info:
processResources {
// this will ensure that this task is redone when the versions change.
inputs.property "version", project.version
inputs.property "mcversion", project.minecraft.version
// replace stuff in mcmod.info, nothing else
from(sourceSets.main.resources.srcDirs) {
include 'mcmod.info'
// replace version and mcversion
expand 'version':project.version, 'mcversion':project.minecraft.version
}
// copy everything else, that's not the mcmod.info
from(sourceSets.main.resources.srcDirs) {
exclude 'mcmod.info'
}
}