mirror of
https://github.com/architectury/architectury-loom.git
synced 2026-03-30 13:05:27 -05:00
Add a lock file around building the loom cache. Regenerate if the lock file exists.
This helps to ensure that failed or canceled builds do not cause the cache to be left in an undetectable invalid state.
This commit is contained in:
@@ -48,7 +48,6 @@ import net.fabricmc.loom.task.LoomTasks;
|
||||
import net.fabricmc.loom.util.LibraryLocationLogger;
|
||||
|
||||
public class LoomGradlePlugin implements BootstrappedPlugin {
|
||||
public static boolean refreshDeps;
|
||||
public static final Gson GSON = new GsonBuilder().setPrettyPrinting().create();
|
||||
public static final ObjectMapper OBJECT_MAPPER = new ObjectMapper().configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
|
||||
public static final String LOOM_VERSION = Objects.requireNonNullElse(LoomGradlePlugin.class.getPackage().getImplementationVersion(), "0.0.0+unknown");
|
||||
@@ -66,12 +65,6 @@ public class LoomGradlePlugin implements BootstrappedPlugin {
|
||||
project.getLogger().lifecycle("Fabric Loom: " + LOOM_VERSION);
|
||||
LibraryLocationLogger.logLibraryVersions();
|
||||
|
||||
refreshDeps = project.getGradle().getStartParameter().isRefreshDependencies() || Boolean.getBoolean("loom.refresh");
|
||||
|
||||
if (refreshDeps) {
|
||||
project.getLogger().lifecycle("Refresh dependencies is in use, loom will be significantly slower.");
|
||||
}
|
||||
|
||||
// Apply default plugins
|
||||
project.apply(ImmutableMap.of("plugin", "java-library"));
|
||||
project.apply(ImmutableMap.of("plugin", "eclipse"));
|
||||
|
||||
Reference in New Issue
Block a user