aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorshedaniel <daniel@shedaniel.me>2021-07-13 17:52:49 +0800
committershedaniel <daniel@shedaniel.me>2021-07-13 18:28:53 +0800
commitad3d7613b8f2faa08709c6b7514866069ce87f74 (patch)
treecda4cb15e02fe5f5c15e2e16e435fd42d243befa /src/main
parentfacd9d61a59aab14ff2f70752bb2343af448e01b (diff)
parentf26e9e2c7b6051823fdfe4a1c34cb02e54564784 (diff)
downloadarchitectury-loom-ad3d7613b8f2faa08709c6b7514866069ce87f74.tar.gz
architectury-loom-ad3d7613b8f2faa08709c6b7514866069ce87f74.tar.bz2
architectury-loom-ad3d7613b8f2faa08709c6b7514866069ce87f74.zip
Merge remote-tracking branch 'FabricMC/dev/0.9' into dev/0.9
Signed-off-by: shedaniel <daniel@shedaniel.me>
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/net/fabricmc/loom/LoomGradleExtension.java2
-rw-r--r--src/main/java/net/fabricmc/loom/LoomGradlePlugin.java2
-rw-r--r--src/main/java/net/fabricmc/loom/LoomRepositoryPlugin.java2
-rw-r--r--src/main/java/net/fabricmc/loom/api/decompilers/DecompilationMetadata.java2
-rw-r--r--src/main/java/net/fabricmc/loom/api/decompilers/LoomDecompiler.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/JarRemapper.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/MixinRefmapHelper.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/ModCompileRemapper.java77
-rw-r--r--src/main/java/net/fabricmc/loom/build/mixin/AnnotationProcessorInvoker.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/mixin/JavaApInvoker.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/mixin/KaptApInvoker.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/mixin/ScalaApInvoker.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/nesting/JarNester.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/nesting/MergedNestedJarProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/nesting/NestedDependencyProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/nesting/NestedJarPathProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/build/nesting/NestedJarProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/DependencyProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/FabricApiExtension.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/LoomDependencyManager.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/LoomProjectData.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/MavenPublication.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/RemapConfiguration.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/RemappedConfigurationEntry.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/accesswidener/AccessWidenerJarProcessor.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/ide/IdeConfiguration.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/ide/RunConfig.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/ide/RunConfigSettings.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/ide/SetupIntelijRunConfigs.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/mods/ModProcessor.java11
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/processors/JarProcessor.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/processors/JarProcessorManager.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/processors/MinecraftProcessedProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/processors/dependency/ModDependencyInfo.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/processors/dependency/RemapData.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/LaunchProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProviderImpl.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/GradleMappingContext.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpec.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpecBuilder.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsDependency.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsProcessor.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingContext.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingLayer.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingNamespace.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsCache.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProviderImpl.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsSpec.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingLayer.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingsSpec.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingLayer.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingsSpec.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingLayer.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpec.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpecBuilder.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentPrefixStripingMappingVisitor.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentTreeV1.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/minecraft/ManifestVersion.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftLibraryProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftMappedProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftNativesProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftVersionMeta.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetIndex.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetObject.java2
-rw-r--r--src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/MinecraftAssetsProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/DecompilerConfiguration.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/LineNumberRemapper.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/cfr/FabricCFRDecompiler.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractFernFlowerDecompiler.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractForkedFFExecutor.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricFernFlowerDecompiler.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricForkedFFExecutor.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/FernFlowerUtils.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/ForkingJavaExec.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadIDFFLogger.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadSafeResultSaver.java2
-rw-r--r--src/main/java/net/fabricmc/loom/decompilers/fernflower/TinyJavadocProvider.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/AbstractLoomTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/AbstractRunTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/CleanEclipseRunsTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/DownloadAssetsTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/GenEclipseRunsTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/GenIdeaProjectTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/GenVsCodeProjectTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/GenerateSourcesTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/LoomTasks.java10
-rw-r--r--src/main/java/net/fabricmc/loom/task/MigrateMappingsTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/RemapAllSourcesTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/RemapJarTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/RemapSourcesJarTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/RunClientTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/RunGameTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/RunServerTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/task/UnpickJarTask.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/Checksum.java12
-rw-r--r--src/main/java/net/fabricmc/loom/util/Constants.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/ConsumingOutputStream.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/DeletingFileVisitor.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/GroovyXmlUtil.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/HashedDownloadUtil.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/ModUtils.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/OperatingSystem.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/SourceRemapper.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/StaticPathWatcher.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/TinyRemapperMappingsHelper.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/ZipReprocessorUtil.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/gradle/GradleSupport.java2
-rw-r--r--src/main/java/net/fabricmc/loom/util/gradle/ProgressLogger.java2
111 files changed, 190 insertions, 134 deletions
diff --git a/src/main/java/net/fabricmc/loom/LoomGradleExtension.java b/src/main/java/net/fabricmc/loom/LoomGradleExtension.java
index 0d1f0c20..b3a1168f 100644
--- a/src/main/java/net/fabricmc/loom/LoomGradleExtension.java
+++ b/src/main/java/net/fabricmc/loom/LoomGradleExtension.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/LoomGradlePlugin.java b/src/main/java/net/fabricmc/loom/LoomGradlePlugin.java
index 96c49433..ecac6a76 100644
--- a/src/main/java/net/fabricmc/loom/LoomGradlePlugin.java
+++ b/src/main/java/net/fabricmc/loom/LoomGradlePlugin.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/LoomRepositoryPlugin.java b/src/main/java/net/fabricmc/loom/LoomRepositoryPlugin.java
index de242a72..055b72b6 100644
--- a/src/main/java/net/fabricmc/loom/LoomRepositoryPlugin.java
+++ b/src/main/java/net/fabricmc/loom/LoomRepositoryPlugin.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/api/decompilers/DecompilationMetadata.java b/src/main/java/net/fabricmc/loom/api/decompilers/DecompilationMetadata.java
index c15f5a32..472254e2 100644
--- a/src/main/java/net/fabricmc/loom/api/decompilers/DecompilationMetadata.java
+++ b/src/main/java/net/fabricmc/loom/api/decompilers/DecompilationMetadata.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/api/decompilers/LoomDecompiler.java b/src/main/java/net/fabricmc/loom/api/decompilers/LoomDecompiler.java
index c19a4a8c..294ba5b2 100644
--- a/src/main/java/net/fabricmc/loom/api/decompilers/LoomDecompiler.java
+++ b/src/main/java/net/fabricmc/loom/api/decompilers/LoomDecompiler.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/JarRemapper.java b/src/main/java/net/fabricmc/loom/build/JarRemapper.java
index 67088057..d97bf925 100644
--- a/src/main/java/net/fabricmc/loom/build/JarRemapper.java
+++ b/src/main/java/net/fabricmc/loom/build/JarRemapper.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/MixinRefmapHelper.java b/src/main/java/net/fabricmc/loom/build/MixinRefmapHelper.java
index 1a819a13..bc775746 100644
--- a/src/main/java/net/fabricmc/loom/build/MixinRefmapHelper.java
+++ b/src/main/java/net/fabricmc/loom/build/MixinRefmapHelper.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/ModCompileRemapper.java b/src/main/java/net/fabricmc/loom/build/ModCompileRemapper.java
index 5f72791e..4a4a808b 100644
--- a/src/main/java/net/fabricmc/loom/build/ModCompileRemapper.java
+++ b/src/main/java/net/fabricmc/loom/build/ModCompileRemapper.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -28,11 +28,14 @@ import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
+import java.util.function.Supplier;
import java.util.zip.ZipFile;
+import com.google.common.io.Files;
import org.gradle.api.Project;
import org.gradle.api.artifacts.Configuration;
import org.gradle.api.artifacts.Dependency;
+import org.gradle.api.artifacts.FileCollectionDependency;
import org.gradle.api.artifacts.ModuleDependency;
import org.gradle.api.artifacts.ResolvedArtifact;
import org.gradle.api.artifacts.dsl.DependencyHandler;
@@ -40,9 +43,11 @@ import org.gradle.api.artifacts.query.ArtifactResolutionQuery;
import org.gradle.api.artifacts.result.ArtifactResult;
import org.gradle.api.artifacts.result.ComponentArtifactsResult;
import org.gradle.api.artifacts.result.ResolvedArtifactResult;
+import org.gradle.api.file.FileCollection;
import org.gradle.api.logging.Logger;
import org.gradle.jvm.JvmLibrary;
import org.gradle.language.base.artifact.SourcesArtifact;
+import org.jetbrains.annotations.Nullable;
import net.fabricmc.loom.LoomGradleExtension;
import net.fabricmc.loom.LoomGradlePlugin;
@@ -51,12 +56,21 @@ import net.fabricmc.loom.configuration.RemappedConfigurationEntry;
import net.fabricmc.loom.configuration.mods.ModProcessor;
import net.fabricmc.loom.configuration.processors.dependency.ModDependencyInfo;
import net.fabricmc.loom.configuration.processors.dependency.RemapData;
+import net.fabricmc.loom.util.Checksum;
import net.fabricmc.loom.util.Constants;
import net.fabricmc.loom.util.OperatingSystem;
import net.fabricmc.loom.util.SourceRemapper;
@SuppressWarnings("UnstableApiUsage")
public class ModCompileRemapper {
+ // This is a placeholder that is used when the actual group is missing (null or empty).
+ // This can happen when the dependency is a FileCollectionDependency or from a flatDir repository.
+ private static final String MISSING_GROUP = "unspecified";
+
+ private static String replaceIfNullOrEmpty(@Nullable String s, Supplier<String> fallback) {
+ return s == null || s.isEmpty() ? fallback.get() : s;
+ }
+
public static void remapDependencies(Project project, String mappingsSuffix, LoomGradleExtension extension, SourceRemapper sourceRemapper) {
Logger logger = project.getLogger();
DependencyHandler dependencies = project.getDependencies();
@@ -75,29 +89,18 @@ public class ModCompileRemapper {
List<ModDependencyInfo> modDependencies = new ArrayList<>();
for (ResolvedArtifact artifact : sourceConfig.getResolvedConfiguration().getResolvedArtifacts()) {
- // TODO: This collection doesn't appear to include FileCollection dependencies
- // Might have to go based on the dependencies, rather than their resolved form?
- // File dependencies use SelfResolvingDependency, which appears to be handled differently
- String group = artifact.getModuleVersion().getId().getGroup();
+ String group = replaceIfNullOrEmpty(artifact.getModuleVersion().getId().getGroup(), () -> MISSING_GROUP);
String name = artifact.getModuleVersion().getId().getName();
- String version = artifact.getModuleVersion().getId().getVersion();
+ String version = replaceIfNullOrEmpty(artifact.getModuleVersion().getId().getVersion(), () -> Checksum.truncatedSha256(artifact.getFile()));
- if (!shouldRemapMod(logger, artifact, extension.isForge(), sourceConfig.getName())) {
+ if (!shouldRemapMod(logger, artifact.getFile(), artifact.getId(), extension.isForge(), sourceConfig.getName())) {
addToRegularCompile(project, regularConfig, artifact);
continue;
}
ModDependencyInfo info = new ModDependencyInfo(group, name, version, artifact.getClassifier(), artifact.getFile(), remappedConfig, remapData);
-
- if (refreshDeps) {
- info.forceRemap();
- }
-
modDependencies.add(info);
- String remappedLog = group + ":" + name + ":" + version + (artifact.getClassifier() == null ? "" : ":" + artifact.getClassifier()) + " (" + mappingsSuffix + ")" + (info.requiresRemapping() ? " requires remapping" : " already remapped in " + info.getRemappedOutput().getAbsolutePath());
- project.getLogger().info(":providing " + remappedLog);
-
File remappedSources = info.getRemappedOutput("sources");
if ((!remappedSources.exists() || refreshDeps) && !OperatingSystem.isCIBuild()) {
@@ -109,6 +112,36 @@ public class ModCompileRemapper {
}
}
+ // FileCollectionDependency (files/fileTree) doesn't resolve properly,
+ // so we have to "resolve" it on our own. The naming is "abc.jar" => "unspecified:abc:unspecified".
+ for (FileCollectionDependency dependency : sourceConfig.getAllDependencies().withType(FileCollectionDependency.class)) {
+ String group = replaceIfNullOrEmpty(dependency.getGroup(), () -> MISSING_GROUP);
+ FileCollection files = dependency.getFiles();
+
+ // Create a mod dependency for each file in the file collection
+ for (File artifact : files) {
+ if (!shouldRemapMod(logger, artifact, artifact.getName(), extension.isForge(), sourceConfig.getName())) {
+ dependencies.add(regularConfig.getName(), project.files(artifact));
+ continue;
+ }
+
+ String name = Files.getNameWithoutExtension(artifact.getAbsolutePath());
+ String version = replaceIfNullOrEmpty(dependency.getVersion(), () -> Checksum.truncatedSha256(artifact));
+
+ ModDependencyInfo info = new ModDependencyInfo(group, name, version, null, artifact, remappedConfig, remapData);
+ modDependencies.add(info);
+ }
+ }
+
+ for (ModDependencyInfo info : modDependencies) {
+ if (refreshDeps) {
+ info.forceRemap();
+ }
+
+ String remappedLog = info.getRemappedNotation() + " (" + mappingsSuffix + ")";
+ project.getLogger().info(":providing " + remappedLog);
+ }
+
try {
ModProcessor.processMods(project, modDependencies);
} catch (IOException e) {
@@ -129,26 +162,24 @@ public class ModCompileRemapper {
/**
* Checks if an artifact is a fabric mod, according to the presence of a fabric.mod.json.
*/
- private static boolean shouldRemapMod(Logger logger, ResolvedArtifact artifact, boolean forge, String config) {
- File input = artifact.getFile();
-
- try (ZipFile zipFile = new ZipFile(input)) {
+ private static boolean shouldRemapMod(Logger logger, File artifact, Object id, boolean forge, String config) {
+ try (ZipFile zipFile = new ZipFile(artifact)) {
if (zipFile.getEntry("architectury.common.marker") != null) {
- logger.info("Found architectury common mod in " + config + ": {}", artifact.getId());
+ logger.info("Found architectury common mod in " + config + ": {}", id);
return true;
}
if (forge) {
if (zipFile.getEntry("META-INF/mods.toml") != null) {
- logger.info("Found Forge mod in " + config + ": {}", artifact.getId());
+ logger.info("Found Forge mod in " + config + ": {}", id);
return true;
}
- logger.lifecycle(":could not find forge mod in " + config + " but forcing: {}", artifact.getId());
+ logger.lifecycle(":could not find forge mod in " + config + " but forcing: {}", id);
return true;
} else {
if (zipFile.getEntry("fabric.mod.json") != null) {
- logger.info("Found Fabric mod in " + config + ": {}", artifact.getId());
+ logger.info("Found Fabric mod in " + config + ": {}", id);
return true;
}
}
diff --git a/src/main/java/net/fabricmc/loom/build/mixin/AnnotationProcessorInvoker.java b/src/main/java/net/fabricmc/loom/build/mixin/AnnotationProcessorInvoker.java
index a0c3987b..bb2f2f19 100644
--- a/src/main/java/net/fabricmc/loom/build/mixin/AnnotationProcessorInvoker.java
+++ b/src/main/java/net/fabricmc/loom/build/mixin/AnnotationProcessorInvoker.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/mixin/JavaApInvoker.java b/src/main/java/net/fabricmc/loom/build/mixin/JavaApInvoker.java
index 2e52d0d7..aa7d46a7 100644
--- a/src/main/java/net/fabricmc/loom/build/mixin/JavaApInvoker.java
+++ b/src/main/java/net/fabricmc/loom/build/mixin/JavaApInvoker.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/mixin/KaptApInvoker.java b/src/main/java/net/fabricmc/loom/build/mixin/KaptApInvoker.java
index 41d6d0ba..5443855a 100644
--- a/src/main/java/net/fabricmc/loom/build/mixin/KaptApInvoker.java
+++ b/src/main/java/net/fabricmc/loom/build/mixin/KaptApInvoker.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/mixin/ScalaApInvoker.java b/src/main/java/net/fabricmc/loom/build/mixin/ScalaApInvoker.java
index 7fed5610..bc77e152 100644
--- a/src/main/java/net/fabricmc/loom/build/mixin/ScalaApInvoker.java
+++ b/src/main/java/net/fabricmc/loom/build/mixin/ScalaApInvoker.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/nesting/JarNester.java b/src/main/java/net/fabricmc/loom/build/nesting/JarNester.java
index 6330b612..662fc2cf 100644
--- a/src/main/java/net/fabricmc/loom/build/nesting/JarNester.java
+++ b/src/main/java/net/fabricmc/loom/build/nesting/JarNester.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/nesting/MergedNestedJarProvider.java b/src/main/java/net/fabricmc/loom/build/nesting/MergedNestedJarProvider.java
index 61b05eb6..48b4db01 100644
--- a/src/main/java/net/fabricmc/loom/build/nesting/MergedNestedJarProvider.java
+++ b/src/main/java/net/fabricmc/loom/build/nesting/MergedNestedJarProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/nesting/NestedDependencyProvider.java b/src/main/java/net/fabricmc/loom/build/nesting/NestedDependencyProvider.java
index 60640cb6..2dae34f6 100644
--- a/src/main/java/net/fabricmc/loom/build/nesting/NestedDependencyProvider.java
+++ b/src/main/java/net/fabricmc/loom/build/nesting/NestedDependencyProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/nesting/NestedJarPathProvider.java b/src/main/java/net/fabricmc/loom/build/nesting/NestedJarPathProvider.java
index 184617ff..deccda49 100644
--- a/src/main/java/net/fabricmc/loom/build/nesting/NestedJarPathProvider.java
+++ b/src/main/java/net/fabricmc/loom/build/nesting/NestedJarPathProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/build/nesting/NestedJarProvider.java b/src/main/java/net/fabricmc/loom/build/nesting/NestedJarProvider.java
index 3ddbae31..79c605ce 100644
--- a/src/main/java/net/fabricmc/loom/build/nesting/NestedJarProvider.java
+++ b/src/main/java/net/fabricmc/loom/build/nesting/NestedJarProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java b/src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java
index e4f6fea6..23cbaf6f 100644
--- a/src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java
+++ b/src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/DependencyProvider.java b/src/main/java/net/fabricmc/loom/configuration/DependencyProvider.java
index 38b9b30d..9f6d6db3 100644
--- a/src/main/java/net/fabricmc/loom/configuration/DependencyProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/DependencyProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/FabricApiExtension.java b/src/main/java/net/fabricmc/loom/configuration/FabricApiExtension.java
index a09262cd..59925bcb 100644
--- a/src/main/java/net/fabricmc/loom/configuration/FabricApiExtension.java
+++ b/src/main/java/net/fabricmc/loom/configuration/FabricApiExtension.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/LoomDependencyManager.java b/src/main/java/net/fabricmc/loom/configuration/LoomDependencyManager.java
index 1d5487d4..9daaa7c7 100644
--- a/src/main/java/net/fabricmc/loom/configuration/LoomDependencyManager.java
+++ b/src/main/java/net/fabricmc/loom/configuration/LoomDependencyManager.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/LoomProjectData.java b/src/main/java/net/fabricmc/loom/configuration/LoomProjectData.java
index 2825ac18..a45df51c 100644
--- a/src/main/java/net/fabricmc/loom/configuration/LoomProjectData.java
+++ b/src/main/java/net/fabricmc/loom/configuration/LoomProjectData.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/MavenPublication.java b/src/main/java/net/fabricmc/loom/configuration/MavenPublication.java
index ab2176f1..178f9aa7 100644
--- a/src/main/java/net/fabricmc/loom/configuration/MavenPublication.java
+++ b/src/main/java/net/fabricmc/loom/configuration/MavenPublication.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/RemapConfiguration.java b/src/main/java/net/fabricmc/loom/configuration/RemapConfiguration.java
index 831e17cb..27244f35 100644
--- a/src/main/java/net/fabricmc/loom/configuration/RemapConfiguration.java
+++ b/src/main/java/net/fabricmc/loom/configuration/RemapConfiguration.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/RemappedConfigurationEntry.java b/src/main/java/net/fabricmc/loom/configuration/RemappedConfigurationEntry.java
index ca2fd995..228ec34e 100644
--- a/src/main/java/net/fabricmc/loom/configuration/RemappedConfigurationEntry.java
+++ b/src/main/java/net/fabricmc/loom/configuration/RemappedConfigurationEntry.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/accesswidener/AccessWidenerJarProcessor.java b/src/main/java/net/fabricmc/loom/configuration/accesswidener/AccessWidenerJarProcessor.java
index 79695d45..0d428bac 100644
--- a/src/main/java/net/fabricmc/loom/configuration/accesswidener/AccessWidenerJarProcessor.java
+++ b/src/main/java/net/fabricmc/loom/configuration/accesswidener/AccessWidenerJarProcessor.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/ide/IdeConfiguration.java b/src/main/java/net/fabricmc/loom/configuration/ide/IdeConfiguration.java
index 364981c1..0c2ec2ef 100644
--- a/src/main/java/net/fabricmc/loom/configuration/ide/IdeConfiguration.java
+++ b/src/main/java/net/fabricmc/loom/configuration/ide/IdeConfiguration.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/ide/RunConfig.java b/src/main/java/net/fabricmc/loom/configuration/ide/RunConfig.java
index 16b134d0..cecfba3c 100644
--- a/src/main/java/net/fabricmc/loom/configuration/ide/RunConfig.java
+++ b/src/main/java/net/fabricmc/loom/configuration/ide/RunConfig.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/ide/RunConfigSettings.java b/src/main/java/net/fabricmc/loom/configuration/ide/RunConfigSettings.java
index fc17c00a..66956521 100644
--- a/src/main/java/net/fabricmc/loom/configuration/ide/RunConfigSettings.java
+++ b/src/main/java/net/fabricmc/loom/configuration/ide/RunConfigSettings.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/ide/SetupIntelijRunConfigs.java b/src/main/java/net/fabricmc/loom/configuration/ide/SetupIntelijRunConfigs.java
index d3911d18..5bc388a5 100644
--- a/src/main/java/net/fabricmc/loom/configuration/ide/SetupIntelijRunConfigs.java
+++ b/src/main/java/net/fabricmc/loom/configuration/ide/SetupIntelijRunConfigs.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/mods/ModProcessor.java b/src/main/java/net/fabricmc/loom/configuration/mods/ModProcessor.java
index 25607f5c..6653de37 100644
--- a/src/main/java/net/fabricmc/loom/configuration/mods/ModProcessor.java
+++ b/src/main/java/net/fabricmc/loom/configuration/mods/ModProcessor.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -190,7 +190,14 @@ public class ModProcessor {
// Apply this in a second loop as we need to ensure all the inputs are on the classpath before remapping.
for (ModDependencyInfo info : remapList) {
- OutputConsumerPath outputConsumer = new OutputConsumerPath.Builder(info.getRemappedOutput().toPath()).build();
+ OutputConsumerPath outputConsumer;
+
+ try {
+ outputConsumer = new OutputConsumerPath.Builder(info.getRemappedOutput().toPath()).build();
+ } catch (Exception e) {
+ throw new IOException("Could not create output consumer for " + info.getRemappedOutput().getAbsolutePath());
+ }
+
outputConsumer.addNonClassFiles(info.getInputFile().toPath());
outputConsumerMap.put(info, outputConsumer);
String accessWidener = info.getAccessWidener();
diff --git a/src/main/java/net/fabricmc/loom/configuration/processors/JarProcessor.java b/src/main/java/net/fabricmc/loom/configuration/processors/JarProcessor.java
index 85624ce1..33cde23b 100644
--- a/src/main/java/net/fabricmc/loom/configuration/processors/JarProcessor.java
+++ b/src/main/java/net/fabricmc/loom/configuration/processors/JarProcessor.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/processors/JarProcessorManager.java b/src/main/java/net/fabricmc/loom/configuration/processors/JarProcessorManager.java
index 634f4bba..9ee6864d 100644
--- a/src/main/java/net/fabricmc/loom/configuration/processors/JarProcessorManager.java
+++ b/src/main/java/net/fabricmc/loom/configuration/processors/JarProcessorManager.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/processors/MinecraftProcessedProvider.java b/src/main/java/net/fabricmc/loom/configuration/processors/MinecraftProcessedProvider.java
index 596dba93..22badc39 100644
--- a/src/main/java/net/fabricmc/loom/configuration/processors/MinecraftProcessedProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/processors/MinecraftProcessedProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/processors/dependency/ModDependencyInfo.java b/src/main/java/net/fabricmc/loom/configuration/processors/dependency/ModDependencyInfo.java
index e7437621..e043ce73 100644
--- a/src/main/java/net/fabricmc/loom/configuration/processors/dependency/ModDependencyInfo.java
+++ b/src/main/java/net/fabricmc/loom/configuration/processors/dependency/ModDependencyInfo.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/processors/dependency/RemapData.java b/src/main/java/net/fabricmc/loom/configuration/processors/dependency/RemapData.java
index cbb92cb2..c3483029 100644
--- a/src/main/java/net/fabricmc/loom/configuration/processors/dependency/RemapData.java
+++ b/src/main/java/net/fabricmc/loom/configuration/processors/dependency/RemapData.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/LaunchProvider.java b/src/main/java/net/fabricmc/loom/configuration/providers/LaunchProvider.java
index 521bf450..45ce2f81 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/LaunchProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/LaunchProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProvider.java b/src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProvider.java
index fed7f5fb..ca493986 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProviderImpl.java b/src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProviderImpl.java
index b6399e91..0ecb49ff 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProviderImpl.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/MinecraftProviderImpl.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/GradleMappingContext.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/GradleMappingContext.java
index d9357014..478896d1 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/GradleMappingContext.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/GradleMappingContext.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpec.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpec.java
index 9f86fb5d..2e47af39 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpec.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpec.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpecBuilder.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpecBuilder.java
index ac4fac49..8b5a471d 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpecBuilder.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingSpecBuilder.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsDependency.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsDependency.java
index ddc1664d..1b5d673f 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsDependency.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsDependency.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsProcessor.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsProcessor.java
index cc45ea6f..a3fa5294 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsProcessor.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/LayeredMappingsProcessor.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingContext.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingContext.java
index 5ae5ea6f..3fbfb655 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingContext.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingContext.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingLayer.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingLayer.java
index 2fdd451f..f3717894 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingLayer.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingLayer.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingNamespace.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingNamespace.java
index 8ac400ad..991cdc79 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingNamespace.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingNamespace.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsCache.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsCache.java
index cbe020d9..29eb5949 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsCache.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsCache.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProvider.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProvider.java
index c2c28280..b150a3de 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProviderImpl.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProviderImpl.java
index 373f6ab5..36837ccf 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProviderImpl.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsProviderImpl.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsSpec.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsSpec.java
index 1666d95c..8b6adcea 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsSpec.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/MappingsSpec.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingLayer.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingLayer.java
index e7fe3938..0ca6414f 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingLayer.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingLayer.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingsSpec.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingsSpec.java
index e4c71fda..866ad9d7 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingsSpec.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/intermediary/IntermediaryMappingsSpec.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingLayer.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingLayer.java
index 835dc910..251ff986 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingLayer.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingLayer.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingsSpec.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingsSpec.java
index 4fa87d7c..67f22460 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingsSpec.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/mojmap/MojangMappingsSpec.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingLayer.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingLayer.java
index 70764234..448a33a1 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingLayer.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingLayer.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpec.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpec.java
index efec61c2..2b3f48b2 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpec.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpec.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpecBuilder.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpecBuilder.java
index 808e077c..1fff3195 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpecBuilder.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentMappingsSpecBuilder.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentPrefixStripingMappingVisitor.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentPrefixStripingMappingVisitor.java
index 6280a5f0..f3d1d823 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentPrefixStripingMappingVisitor.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentPrefixStripingMappingVisitor.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentTreeV1.java b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentTreeV1.java
index 6d9c1a6c..e41f8a83 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentTreeV1.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/mappings/parchment/ParchmentTreeV1.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/ManifestVersion.java b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/ManifestVersion.java
index d4108b14..f60bf6e4 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/ManifestVersion.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/ManifestVersion.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftLibraryProvider.java b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftLibraryProvider.java
index bfb42d74..0089b935 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftLibraryProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftLibraryProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftMappedProvider.java b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftMappedProvider.java
index db09229e..9fc53fd2 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftMappedProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftMappedProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftNativesProvider.java b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftNativesProvider.java
index f57db002..587c42ab 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftNativesProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftNativesProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftVersionMeta.java b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftVersionMeta.java
index 7f0539e9..58a20dba 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftVersionMeta.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/MinecraftVersionMeta.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetIndex.java b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetIndex.java
index 6c1b8ead..c87fc8c8 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetIndex.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetIndex.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetObject.java b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetObject.java
index 0380d9ba..b7e63b12 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetObject.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/AssetObject.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/MinecraftAssetsProvider.java b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/MinecraftAssetsProvider.java
index 00fb88c8..edc3aea8 100644
--- a/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/MinecraftAssetsProvider.java
+++ b/src/main/java/net/fabricmc/loom/configuration/providers/minecraft/assets/MinecraftAssetsProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/DecompilerConfiguration.java b/src/main/java/net/fabricmc/loom/decompilers/DecompilerConfiguration.java
index 5ec54664..322e6dc3 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/DecompilerConfiguration.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/DecompilerConfiguration.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/LineNumberRemapper.java b/src/main/java/net/fabricmc/loom/decompilers/LineNumberRemapper.java
index 4bec4e71..c2cb4d06 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/LineNumberRemapper.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/LineNumberRemapper.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/cfr/FabricCFRDecompiler.java b/src/main/java/net/fabricmc/loom/decompilers/cfr/FabricCFRDecompiler.java
index d0ffa406..7237a499 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/cfr/FabricCFRDecompiler.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/cfr/FabricCFRDecompiler.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractFernFlowerDecompiler.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractFernFlowerDecompiler.java
index 4d8d7257..d0b5c56d 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractFernFlowerDecompiler.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractFernFlowerDecompiler.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractForkedFFExecutor.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractForkedFFExecutor.java
index d42bf7ff..2435233e 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractForkedFFExecutor.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/AbstractForkedFFExecutor.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricFernFlowerDecompiler.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricFernFlowerDecompiler.java
index 7fc98ab2..b3663773 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricFernFlowerDecompiler.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricFernFlowerDecompiler.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricForkedFFExecutor.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricForkedFFExecutor.java
index 708acab2..e88c8086 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricForkedFFExecutor.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/FabricForkedFFExecutor.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/FernFlowerUtils.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/FernFlowerUtils.java
index 2f999b32..ced6345c 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/FernFlowerUtils.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/FernFlowerUtils.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/ForkingJavaExec.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/ForkingJavaExec.java
index 90080d69..836726af 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/ForkingJavaExec.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/ForkingJavaExec.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadIDFFLogger.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadIDFFLogger.java
index cdbe90bc..a7b617bc 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadIDFFLogger.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadIDFFLogger.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadSafeResultSaver.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadSafeResultSaver.java
index 66598749..e5eb867c 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadSafeResultSaver.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/ThreadSafeResultSaver.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/decompilers/fernflower/TinyJavadocProvider.java b/src/main/java/net/fabricmc/loom/decompilers/fernflower/TinyJavadocProvider.java
index 07db43f1..dee4820e 100644
--- a/src/main/java/net/fabricmc/loom/decompilers/fernflower/TinyJavadocProvider.java
+++ b/src/main/java/net/fabricmc/loom/decompilers/fernflower/TinyJavadocProvider.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/AbstractLoomTask.java b/src/main/java/net/fabricmc/loom/task/AbstractLoomTask.java
index e1f4db16..430416f8 100644
--- a/src/main/java/net/fabricmc/loom/task/AbstractLoomTask.java
+++ b/src/main/java/net/fabricmc/loom/task/AbstractLoomTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/AbstractRunTask.java b/src/main/java/net/fabricmc/loom/task/AbstractRunTask.java
index 111d074a..cad89ae8 100644
--- a/src/main/java/net/fabricmc/loom/task/AbstractRunTask.java
+++ b/src/main/java/net/fabricmc/loom/task/AbstractRunTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/CleanEclipseRunsTask.java b/src/main/java/net/fabricmc/loom/task/CleanEclipseRunsTask.java
index 5b11901b..5b7a700f 100644
--- a/src/main/java/net/fabricmc/loom/task/CleanEclipseRunsTask.java
+++ b/src/main/java/net/fabricmc/loom/task/CleanEclipseRunsTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/DownloadAssetsTask.java b/src/main/java/net/fabricmc/loom/task/DownloadAssetsTask.java
index 3a5dba87..d862ea50 100644
--- a/src/main/java/net/fabricmc/loom/task/DownloadAssetsTask.java
+++ b/src/main/java/net/fabricmc/loom/task/DownloadAssetsTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/GenEclipseRunsTask.java b/src/main/java/net/fabricmc/loom/task/GenEclipseRunsTask.java
index 5a3c868b..fbc2ef13 100644
--- a/src/main/java/net/fabricmc/loom/task/GenEclipseRunsTask.java
+++ b/src/main/java/net/fabricmc/loom/task/GenEclipseRunsTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/GenIdeaProjectTask.java b/src/main/java/net/fabricmc/loom/task/GenIdeaProjectTask.java
index dbf19a65..2e269833 100644
--- a/src/main/java/net/fabricmc/loom/task/GenIdeaProjectTask.java
+++ b/src/main/java/net/fabricmc/loom/task/GenIdeaProjectTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/GenVsCodeProjectTask.java b/src/main/java/net/fabricmc/loom/task/GenVsCodeProjectTask.java
index d134e343..48d46b06 100644
--- a/src/main/java/net/fabricmc/loom/task/GenVsCodeProjectTask.java
+++ b/src/main/java/net/fabricmc/loom/task/GenVsCodeProjectTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/GenerateSourcesTask.java b/src/main/java/net/fabricmc/loom/task/GenerateSourcesTask.java
index 4b180030..e66822b0 100644
--- a/src/main/java/net/fabricmc/loom/task/GenerateSourcesTask.java
+++ b/src/main/java/net/fabricmc/loom/task/GenerateSourcesTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/LoomTasks.java b/src/main/java/net/fabricmc/loom/task/LoomTasks.java
index f91b3348..4c7c46a6 100644
--- a/src/main/java/net/fabricmc/loom/task/LoomTasks.java
+++ b/src/main/java/net/fabricmc/loom/task/LoomTasks.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -126,6 +126,14 @@ public final class LoomTasks {
project.afterEvaluate(p -> {
MappingsProviderImpl mappingsProvider = extension.getMappingsProvider();
+
+ if (mappingsProvider.mappedProvider == null) {
+ // If this is ever null something has gone badly wrong,
+ // for some reason for another this afterEvaluate still gets called when something has gone badly
+ // wrong, returning here seems to produce nicer errors.
+ return;
+ }
+
File inputJar = mappingsProvider.mappedProvider.getMappedJar();
if (mappingsProvider.hasUnpickDefinitions()) {
diff --git a/src/main/java/net/fabricmc/loom/task/MigrateMappingsTask.java b/src/main/java/net/fabricmc/loom/task/MigrateMappingsTask.java
index 7f7074de..9ebbba9d 100644
--- a/src/main/java/net/fabricmc/loom/task/MigrateMappingsTask.java
+++ b/src/main/java/net/fabricmc/loom/task/MigrateMappingsTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2019-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/RemapAllSourcesTask.java b/src/main/java/net/fabricmc/loom/task/RemapAllSourcesTask.java
index 06bdfcf1..62bff631 100644
--- a/src/main/java/net/fabricmc/loom/task/RemapAllSourcesTask.java
+++ b/src/main/java/net/fabricmc/loom/task/RemapAllSourcesTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/RemapJarTask.java b/src/main/java/net/fabricmc/loom/task/RemapJarTask.java
index 49e57c8d..c82dec79 100644
--- a/src/main/java/net/fabricmc/loom/task/RemapJarTask.java
+++ b/src/main/java/net/fabricmc/loom/task/RemapJarTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/RemapSourcesJarTask.java b/src/main/java/net/fabricmc/loom/task/RemapSourcesJarTask.java
index 4b7f6635..0d7506e7 100644
--- a/src/main/java/net/fabricmc/loom/task/RemapSourcesJarTask.java
+++ b/src/main/java/net/fabricmc/loom/task/RemapSourcesJarTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/RunClientTask.java b/src/main/java/net/fabricmc/loom/task/RunClientTask.java
index 12504b68..da895b0a 100644
--- a/src/main/java/net/fabricmc/loom/task/RunClientTask.java
+++ b/src/main/java/net/fabricmc/loom/task/RunClientTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/RunGameTask.java b/src/main/java/net/fabricmc/loom/task/RunGameTask.java
index f82352a0..421d34dc 100644
--- a/src/main/java/net/fabricmc/loom/task/RunGameTask.java
+++ b/src/main/java/net/fabricmc/loom/task/RunGameTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/RunServerTask.java b/src/main/java/net/fabricmc/loom/task/RunServerTask.java
index 7188ce68..fea4223d 100644
--- a/src/main/java/net/fabricmc/loom/task/RunServerTask.java
+++ b/src/main/java/net/fabricmc/loom/task/RunServerTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/task/UnpickJarTask.java b/src/main/java/net/fabricmc/loom/task/UnpickJarTask.java
index 7f66aa61..2d4bd3cc 100644
--- a/src/main/java/net/fabricmc/loom/task/UnpickJarTask.java
+++ b/src/main/java/net/fabricmc/loom/task/UnpickJarTask.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/Checksum.java b/src/main/java/net/fabricmc/loom/util/Checksum.java
index 23690905..ba9cd2e6 100644
--- a/src/main/java/net/fabricmc/loom/util/Checksum.java
+++ b/src/main/java/net/fabricmc/loom/util/Checksum.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -26,6 +26,7 @@ package net.fabricmc.loom.util;
import java.io.File;
import java.io.IOException;
+import java.io.UncheckedIOException;
import java.nio.charset.StandardCharsets;
import com.google.common.hash.HashCode;
@@ -63,6 +64,15 @@ public class Checksum {
}
}
+ public static String truncatedSha256(File file) {
+ try {
+ HashCode hash = Files.asByteSource(file).hash(Hashing.sha256());
+ return hash.toString().substring(0, 12);
+ } catch (IOException e) {
+ throw new UncheckedIOException("Failed to get file hash of " + file, e);
+ }
+ }
+
public static byte[] sha256(String string) {
HashCode hash = Hashing.sha256().hashString(string, StandardCharsets.UTF_8);
return hash.asBytes();
diff --git a/src/main/java/net/fabricmc/loom/util/Constants.java b/src/main/java/net/fabricmc/loom/util/Constants.java
index 2ee721ed..5d2806dd 100644
--- a/src/main/java/net/fabricmc/loom/util/Constants.java
+++ b/src/main/java/net/fabricmc/loom/util/Constants.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/ConsumingOutputStream.java b/src/main/java/net/fabricmc/loom/util/ConsumingOutputStream.java
index 8ba6767c..98c16e1b 100644
--- a/src/main/java/net/fabricmc/loom/util/ConsumingOutputStream.java
+++ b/src/main/java/net/fabricmc/loom/util/ConsumingOutputStream.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/DeletingFileVisitor.java b/src/main/java/net/fabricmc/loom/util/DeletingFileVisitor.java
index 491ab182..0bf97022 100644
--- a/src/main/java/net/fabricmc/loom/util/DeletingFileVisitor.java
+++ b/src/main/java/net/fabricmc/loom/util/DeletingFileVisitor.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2018 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/GroovyXmlUtil.java b/src/main/java/net/fabricmc/loom/util/GroovyXmlUtil.java
index fcc9d9cd..65e9136e 100644
--- a/src/main/java/net/fabricmc/loom/util/GroovyXmlUtil.java
+++ b/src/main/java/net/fabricmc/loom/util/GroovyXmlUtil.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/HashedDownloadUtil.java b/src/main/java/net/fabricmc/loom/util/HashedDownloadUtil.java
index a03126d1..712043da 100644
--- a/src/main/java/net/fabricmc/loom/util/HashedDownloadUtil.java
+++ b/src/main/java/net/fabricmc/loom/util/HashedDownloadUtil.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2020-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/ModUtils.java b/src/main/java/net/fabricmc/loom/util/ModUtils.java
index 1dfc43b2..527bd7dc 100644
--- a/src/main/java/net/fabricmc/loom/util/ModUtils.java
+++ b/src/main/java/net/fabricmc/loom/util/ModUtils.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/OperatingSystem.java b/src/main/java/net/fabricmc/loom/util/OperatingSystem.java
index db622790..38e2eb4a 100644
--- a/src/main/java/net/fabricmc/loom/util/OperatingSystem.java
+++ b/src/main/java/net/fabricmc/loom/util/OperatingSystem.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/SourceRemapper.java b/src/main/java/net/fabricmc/loom/util/SourceRemapper.java
index f3b51303..b1283fc9 100644
--- a/src/main/java/net/fabricmc/loom/util/SourceRemapper.java
+++ b/src/main/java/net/fabricmc/loom/util/SourceRemapper.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2018-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/StaticPathWatcher.java b/src/main/java/net/fabricmc/loom/util/StaticPathWatcher.java
index 2dd9b08d..ffdced68 100644
--- a/src/main/java/net/fabricmc/loom/util/StaticPathWatcher.java
+++ b/src/main/java/net/fabricmc/loom/util/StaticPathWatcher.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/TinyRemapperMappingsHelper.java b/src/main/java/net/fabricmc/loom/util/TinyRemapperMappingsHelper.java
index 92e5bf94..f5b9b911 100644
--- a/src/main/java/net/fabricmc/loom/util/TinyRemapperMappingsHelper.java
+++ b/src/main/java/net/fabricmc/loom/util/TinyRemapperMappingsHelper.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2019 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/ZipReprocessorUtil.java b/src/main/java/net/fabricmc/loom/util/ZipReprocessorUtil.java
index 735b3346..43b28db5 100644
--- a/src/main/java/net/fabricmc/loom/util/ZipReprocessorUtil.java
+++ b/src/main/java/net/fabricmc/loom/util/ZipReprocessorUtil.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/gradle/GradleSupport.java b/src/main/java/net/fabricmc/loom/util/gradle/GradleSupport.java
index 6c72d5be..0ac6bab0 100644
--- a/src/main/java/net/fabricmc/loom/util/gradle/GradleSupport.java
+++ b/src/main/java/net/fabricmc/loom/util/gradle/GradleSupport.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2021 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
diff --git a/src/main/java/net/fabricmc/loom/util/gradle/ProgressLogger.java b/src/main/java/net/fabricmc/loom/util/gradle/ProgressLogger.java
index 448331d5..2b3d180e 100644
--- a/src/main/java/net/fabricmc/loom/util/gradle/ProgressLogger.java
+++ b/src/main/java/net/fabricmc/loom/util/gradle/ProgressLogger.java
@@ -1,7 +1,7 @@
/*
* This file is part of fabric-loom, licensed under the MIT License (MIT).
*
- * Copyright (c) 2016, 2017, 2018 FabricMC
+ * Copyright (c) 2016-2020 FabricMC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal