Merge Forge 1.10.2 into common gradle build
This commit is contained in:
parent
188e2bbe5b
commit
aea52cd142
98 changed files with 22414 additions and 0 deletions
94
forge-1.10.2/build.gradle
Normal file
94
forge-1.10.2/build.gradle
Normal file
|
|
@ -0,0 +1,94 @@
|
|||
buildscript {
|
||||
repositories {
|
||||
jcenter()
|
||||
maven {
|
||||
name = "forge"
|
||||
url = "http://files.minecraftforge.net/maven"
|
||||
}
|
||||
maven {url = "https://oss.sonatype.org/content/repositories/snapshots/"}
|
||||
}
|
||||
dependencies {
|
||||
classpath 'net.minecraftforge.gradle:ForgeGradle:2.2-SNAPSHOT'
|
||||
}
|
||||
}
|
||||
|
||||
apply plugin: 'net.minecraftforge.gradle.forge'
|
||||
apply plugin: 'com.github.johnrengelman.shadow'
|
||||
|
||||
dependencies {
|
||||
compile project(path: ":DynmapCoreAPI", configuration: "shadow")
|
||||
compile project(path: ":DynmapCore", configuration: "shadow")
|
||||
}
|
||||
|
||||
sourceCompatibility = 1.8
|
||||
targetCompatibility = 1.8
|
||||
ext.buildNumber = System.getenv().BUILD_NUMBER ?: "Dev"
|
||||
|
||||
repositories {
|
||||
maven {
|
||||
name = 'forge'
|
||||
url = 'http://files.minecraftforge.net/maven'
|
||||
}
|
||||
}
|
||||
minecraft {
|
||||
version = "1.10.2-12.18.3.2316"
|
||||
mappings = "snapshot_20160922"
|
||||
runDir = 'run'
|
||||
}
|
||||
|
||||
project.archivesBaseName = "${project.archivesBaseName}-forge-1.10.2"
|
||||
|
||||
processResources
|
||||
{
|
||||
// replace stuff in mcmod.info, nothing else
|
||||
from(sourceSets.main.resources.srcDirs) {
|
||||
include 'mcmod.info'
|
||||
|
||||
// replace version and mcversion
|
||||
expand(
|
||||
version: project.version + '-' + project.ext.buildNumber,
|
||||
mcversion: "1.10.2"
|
||||
)
|
||||
}
|
||||
|
||||
// copy everything else, thats not the mcmod.info
|
||||
from(sourceSets.main.resources.srcDirs) {
|
||||
exclude 'mcmod.info'
|
||||
}
|
||||
// Move access transformer to META-INF
|
||||
rename '(.+_at.cfg)', 'META-INF/$1'
|
||||
}
|
||||
|
||||
shadowJar {
|
||||
dependencies {
|
||||
include(dependency(':DynmapCore'))
|
||||
include(dependency(':DynmapCoreAPI'))
|
||||
}
|
||||
archiveName = "Dynmap-${parent.version}-forge-1.10.2.jar"
|
||||
destinationDir = file '../target'
|
||||
manifest {
|
||||
attributes 'FMLAT': 'dynmap_at.cfg'
|
||||
}
|
||||
}
|
||||
shadowJar.doLast {
|
||||
task ->
|
||||
ant.checksum file: task.archivePath
|
||||
}
|
||||
|
||||
|
||||
reobf {
|
||||
shadowJar {
|
||||
mappingType = 'SEARGE'
|
||||
}
|
||||
}
|
||||
|
||||
task deobfJar(type: Jar) {
|
||||
from sourceSets.main.output
|
||||
classifier = 'dev'
|
||||
}
|
||||
|
||||
artifacts {
|
||||
archives deobfJar
|
||||
}
|
||||
|
||||
build.dependsOn(shadowJar)
|
||||
Loading…
Add table
Add a link
Reference in a new issue