Flywheel/forge/build.gradle
Jozufozu a44e7f5205 All your script are belong to us
- Port java/subproject convention plugins to kotlin binary plugin
- Fix licence bundling in jars
- Update licence year
2024-05-17 08:43:56 -07:00

75 lines
1.9 KiB
Groovy

plugins {
id 'idea'
id 'java'
id 'maven-publish'
id 'dev.architectury.loom'
id 'flywheel.package-infos'
id 'flywheel.subproject'
id 'flywheel.platform'
id 'flywheel.jar-sets'
id 'flywheel.transitive-source-sets'
}
transitiveSourceSets {
compileClasspath = sourceSets.main.compileClasspath
create('api') {
rootCompile()
}
create('lib') {
rootCompile()
compile sourceSets.api
}
create('backend') {
rootCompile()
compile sourceSets.api, sourceSets.lib
}
sourceSet(sourceSets.main) {
compile sourceSets.api, sourceSets.lib, sourceSets.backend
}
createCompileConfigurations()
}
platform {
commonProject = project(':common')
sources sourceSets.api, sourceSets.lib, sourceSets.backend, sourceSets.main
compileWithCommonSourceSets()
setupLoomMod()
setupLoomRuns()
setupFatJar()
publishMod()
publishRemap(apiArtifactId, jarSets.createJars('api', sourceSets.api, sourceSets.lib))
}
defaultPackageInfos {
sources sourceSets.api, sourceSets.lib, sourceSets.backend, sourceSets.main
}
loom {
forge {
mixinConfig 'flywheel.backend.mixins.json'
mixinConfig 'flywheel.impl.mixins.json'
mixinConfig 'flywheel.impl.sodium.mixins.json'
}
runs {
configureEach {
property 'forge.logging.markers', ''
property 'forge.logging.console.level', 'debug'
}
}
}
dependencies {
forge "net.minecraftforge:forge:${minecraft_version}-${forge_version}"
modCompileOnly "maven.modrinth:embeddium:${embeddium_version}"
modCompileOnly "maven.modrinth:oculus:${oculus_version}"
forApi project(path: ':common', configuration: 'commonApiOnly')
forLib project(path: ':common', configuration: 'commonLib')
forBackend project(path: ':common', configuration: 'commonBackend')
forMain project(path: ':common', configuration: 'commonImpl')
}