Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix publishing #28

Merged
merged 1 commit into from
Jun 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
package net.neoforged.moddevgradle.boot;

import org.gradle.api.Project;

public class RepositoriesPlugin extends TrampolinePlugin<Project> {
public RepositoriesPlugin() {
super("net.neoforged.moddevgradle.internal.RepositoriesPlugin");
}
}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import net.neoforged.moddevgradle.dsl.InternalModelHelper;
import net.neoforged.moddevgradle.dsl.NeoForgeExtension;
import net.neoforged.moddevgradle.dsl.RunModel;
import net.neoforged.moddevgradle.internal.generated.MojangRepositoryFilter;
import net.neoforged.moddevgradle.internal.utils.ExtensionUtils;
import net.neoforged.moddevgradle.internal.utils.FileUtils;
import net.neoforged.moddevgradle.internal.utils.IdeDetection;
Expand Down Expand Up @@ -59,7 +58,6 @@
import java.io.FileWriter;
import java.io.IOException;
import java.io.UncheckedIOException;
import java.net.URI;
import java.nio.file.Files;
import java.util.ArrayList;
import java.util.HashMap;
Expand Down Expand Up @@ -104,8 +102,8 @@ public void apply(Project project) {
project.getPlugins().apply(JavaLibraryPlugin.class);
// Do not apply the repositories automatically if they have been applied at the settings-level.
// It's still possible to apply them manually, though.
if (!project.getGradle().getPlugins().hasPlugin(RepositoryPlugin.class)) {
project.getPlugins().apply(RepositoryPlugin.class);
if (!project.getGradle().getPlugins().hasPlugin(RepositoriesPlugin.class)) {
project.getPlugins().apply(RepositoriesPlugin.class);
} else {
project.getLogger().info("Not enabling NeoForged repositories since they were applied at the settings level");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
* repositories from being added again at the project-level.</li>
* </ul>
*/
public class RepositoryPlugin implements Plugin<PluginAware> {
public class RepositoriesPlugin implements Plugin<PluginAware> {
@Override
public void apply(PluginAware target) {
if (target instanceof Project project) {
Expand Down
Loading