Improve setup speed. (#208)

* Improve access widener remapper, now uses tiny remapper

* First pass on using the new tiny remapper

* Optimise source remapping
This commit is contained in:
modmuss50
2020-05-13 19:44:45 +01:00
committed by GitHub
parent bf6fb4a95e
commit 3eff7d0fdb
13 changed files with 420 additions and 362 deletions

View File

@@ -110,11 +110,16 @@ public class RemapJarTask extends Jar {
remapper.readInputs(input);
remapper.apply(outputConsumer);
} catch (Exception e) {
throw new RuntimeException("Failed to remap " + input + " to " + output, e);
} finally {
remapper.finish();
throw new RuntimeException("Failed to remap " + input + " to " + output, e);
}
if (extension.accessWidener != null) {
extension.getJarProcessorManager().getByType(AccessWidenerJarProcessor.class).remapAccessWidener(output, remapper.getRemapper());
}
remapper.finish();
if (!Files.exists(output)) {
throw new RuntimeException("Failed to remap " + input + " to " + output + " - file missing!");
}
@@ -129,10 +134,6 @@ public class RemapJarTask extends Jar {
}
}
if (extension.accessWidener != null) {
extension.getJarProcessorManager().getByType(AccessWidenerJarProcessor.class).remapAccessWidener(output);
}
/*try {
if (modJar.exists()) {
Files.move(modJar, modJarUnmappedCopy);