Run migration mappings

Everything is still broken, but at least we reduced the amount of errors by hundreds, if not thousands.
This commit is contained in:
Nicholas Ignoffo 2019-09-22 12:55:43 -07:00
parent 1caae69992
commit 4035d91151
484 changed files with 4924 additions and 4962 deletions

View file

@ -1,27 +1,23 @@
buildscript {
repositories {
maven { url = 'https://files.minecraftforge.net/maven' }
jcenter()
mavenCentral()
maven { url "http://files.minecraftforge.net/maven" }
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
}
dependencies {
classpath 'net.minecraftforge.gradle:ForgeGradle:2.3-SNAPSHOT'
classpath group: 'net.minecraftforge.gradle', name: 'ForgeGradle', version: '3.+', changing: true
}
}
plugins {
id "net.minecraftforge.gradle.forge" version "2.0.2"
id 'com.matthewprenger.cursegradle' version '1.1.0'
id 'maven-publish'
id "com.matthewprenger.cursegradle" version "1.3.0"
id "maven-publish"
}
def build_number = 'CUSTOM'
if (System.getenv('BUILD_NUMBER') != null)
build_number = System.getenv('BUILD_NUMBER')
apply plugin: 'net.minecraftforge.gradle'
def username = "${mod_name}"
if (project.hasProperty('dev_username'))
username = "${dev_username}"
def build_number = System.getenv('BUILD_NUMBER') != null ? System.getenv('BUILD_NUMBER') : 'CUSTOM'
def username = project.hasProperty('dev_username') ? "${dev_username}" : "${mod_name}"
group = package_group
archivesBaseName = mod_name
@ -33,38 +29,54 @@ repositories {
}
dependencies {
deobfCompile "mezz.jei:jei_${mc_version}:${jei_version}"
deobfCompile "mcp.mobius.waila:Hwyla:${waila_version}"
deobfCompile "info.amerifrance.guideapi:Guide-API:${guideapi_version}"
minecraft "net.minecraftforge:forge:${mc_version}-${forge_version}"
compile fg.deobf("mezz.jei:jei-${mc_version}:${jei_version}")
compile fg.deobf("mcp.mobius.waila:Hwyla:${waila_version}")
}
minecraft {
version = "${mc_version}-${forge_version}"
runDir = "run"
mappings channel: "snapshot", version: "20190912-1.14.3"
replace "@VERSION@", project.version
replaceIn "BloodMagic.java"
runs {
client {
workingDirectory project.file('run')
property 'forge.logging.markers', ''
property 'forge.logging.console.level', 'info'
property 'username', username
clientRunArgs += "--username=${username}"
mods {
bloodmagic {
source sourceSets.main
}
}
}
if (project.hasProperty('mappings_version'))
mappings = project.mappings_version
server {
workingDirectory project.file('run/server')
property 'forge.logging.markers', ''
property 'forge.logging.console.level', 'info'
mods {
bloodmagic {
source sourceSets.main
}
}
}
}
}
apply from: "gradle/process_mod_info.gradle"
processResources {
inputs.property "version", project.version
inputs.property "mcversion", project.minecraft.version
from(sourceSets.main.resources.srcDirs) {
include '**/*.info'
include '**/*.properties'
include '**/*.toml'
expand 'version': project.version, 'mcversion': project.minecraft.version
expand 'version': project.version
}
from(sourceSets.main.resources.srcDirs) {
exclude '**/*.info'
exclude '**/*.properties'
exclude '**/*.toml'
}
}
@ -77,7 +89,6 @@ allprojects {
jar {
classifier = ''
from sourceSets.main.output
from sourceSets.api.output
manifest.mainAttributes(
"Built-By": System.getProperty('user.name'),
"Created-By": "${System.getProperty('java.vm.version')} + (${System.getProperty('java.vm.vendor')})",
@ -87,28 +98,21 @@ jar {
)
}
// API jar
task apiJar(type: Jar) {
classifier = 'api'
from sourceSets.api.output
// TODO: when FG bug is fixed, remove allJava from the api jar.
// https://github.com/MinecraftForge/ForgeGradle/issues/369
// Gradle should be able to pull them from the -sources jar.
from sourceSets.api.allJava
}
task javadocJar(type: Jar, dependsOn: javadoc) {
from javadoc.destinationDir
classifier = 'javadoc'
include 'com/WayofTime/bloodmagic/api/**/*'
exclude 'com/WayofTime/bloodmagic/api/impl/**/*'
from sourceSets.main.allSource
from sourceSets.main.output
}
task sourcesJar(type: Jar) {
classifier = 'sources'
from sourceSets.main.allJava
from sourceSets.api.allJava
}
tasks.build.dependsOn javadoc, javadocJar, apiJar, sourcesJar
tasks.build.dependsOn apiJar, sourcesJar
tasks.withType(JavaCompile) { task ->
task.options.encoding = 'UTF-8'
@ -119,7 +123,6 @@ publishing {
publications {
mavenJava(MavenPublication) {
artifact jar
artifact javadocJar
artifact sourcesJar
artifact apiJar
}
@ -161,7 +164,6 @@ String getChangelogText() {
def curseRelations = {
optionalLibrary 'jei'
optionalLibrary 'hwyla'
requiredLibrary 'guide-api'
}
curseforge {
@ -175,7 +177,6 @@ curseforge {
relations curseRelations
addArtifact javadocJar
addArtifact sourcesJar
addArtifact apiJar
}