fix: Properly support isolated projects
This commit is contained in:
3 files changed
+78
-22
No files matched your search
+5
-2
@@ -61,8 +61,11 @@ abstract class SmcmtkSettingsPlugin : Plugin<Settings> {
|
||||
settings.gradle.lifecycle.beforeProject { project ->
|
||||
project.extensions.findByType(ExtraPropertiesExtension::class.java)?.apply {
|
||||
// Loom uses the same jar for both plugin variants (plain and remap) and tries to determine
|
||||
// which one is in use by checking the plugin manager.
|
||||
// This doesn't seem to work when using convention plugins, so we're forcing the remapping off here.
|
||||
// which one is in use by checking the plugin manager by the plugin id.
|
||||
// This doesn't work when the Loom plugin is in the classpath already due to convention plugins.
|
||||
// Since in this case Gradle doesn't register the plugin id, we're forcing the remapping off here.
|
||||
// This notably doesn't work in isolated projects as Loom uses providers.gradleProperty there
|
||||
// which can't be overwritten programmatically.
|
||||
set("fabric.loom.disableObfuscation", "true")
|
||||
set("fabric.loom.dontRemap", "true")
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user