Fix checkLicense tasks with projectInfo task

This commit is contained in:
LexManos committed 2026-09-28 11:55:03 -07:00
1 parent ed6d9ff0e4
commit 932c6e9649
2 files changed
+6

No files matched your search

@@ -84,6 +84,7 @@ class ConventionPlugin implements Plugin<Project>, Meta {
license.with {
header = rootProject.file('LICENSE-header.txt')
exclude('.project_info.properties')
}
// Common dependencies,
@@ -6,6 +6,8 @@
package net.minecraftforge.forge.build
import groovy.transform.CompileStatic
import net.minecraftforge.licenser.LicenseExtension
import net.minecraftforge.licenser.tasks.LicenseCheck
import org.gradle.api.Action
import org.gradle.api.Project
import org.gradle.api.tasks.SourceSet
@@ -182,6 +184,9 @@ class Runs implements Meta {
it.property('output', 'src/main/generated')
}
this.project.tasks.named("generateResources").configure { it.dependsOn(projectInfo) }
this.project.tasks.withType(LicenseCheck).configureEach {
it.dependsOn(projectInfo)
}
}
return projectInfo
}