Skip to content

Commit

Permalink
Merge remote-tracking branches 'origin/dependabot/gradle/com.diffplug…
Browse files Browse the repository at this point in the history
….spotless-spotless-plugin-gradle-5.10.2' and 'origin/misc' into main
  • Loading branch information
LunNova committed Feb 20, 2021
2 parents be649a3 + ecf90cb commit dca057d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/main/java/dev/minco/gradle/DefaultsPlugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import java.util.Collections;
import java.util.Objects;

import dev.minco.gradle.changelog.ChangelogTask;
import org.gradle.api.Plugin;
import org.gradle.api.Project;
import org.gradle.api.file.DuplicatesStrategy;
Expand All @@ -21,6 +22,7 @@
import org.jetbrains.annotations.Nullable;

public class DefaultsPlugin implements Plugin<Project> {
public static final String CHANGELOG_TASK_NAME = "mincoGenerateChangelog";
static final Charset CHARSET = StandardCharsets.UTF_8;
DefaultsPluginExtension settings;

Expand All @@ -31,6 +33,7 @@ private static String packageIfExists(@Nullable String in) {
@Override
public void apply(@NotNull Project project) {
project.getExtensions().add("minimallyCorrectDefaults", settings = new DefaultsPluginExtension(project));
project.getTasks().register(CHANGELOG_TASK_NAME, ChangelogTask.class);
project.afterEvaluate(it -> {
if (it.getState().getFailure() != null)
return;
Expand Down

0 comments on commit dca057d

Please sign in to comment.