Skip to content

Commit

Permalink
fix mcmod.info path
Browse files Browse the repository at this point in the history
  • Loading branch information
dxxxxy committed Mar 12, 2022
1 parent 290abed commit 6b7f737
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -76,19 +76,21 @@ dependencies {
}

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
filesMatching("mcmod.info") {
// replace version and mcversion
expand 'version': project.version, 'mcversion': project.minecraft.version
}

exclude "META-INF/**"
//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 {
from("src/main/resources")
into("build/classes/main")
//copy everything else, that"s not the mcmod.info
from(sourceSets.main.resources.srcDirs) {
exclude "mcmod.info"
}

rename '(.+_at.cfg)', 'META-INF/$1'
Expand Down

0 comments on commit 6b7f737

Please sign in to comment.