buildscript { repositories { mavenCentral() gradlePluginPortal() mavenLocal() google() maven { url = 'https://central.sonatype.com/repository/maven-snapshots/' } } dependencies { } } plugins { id 'com.diffplug.spotless' version '6.25.0' apply false } allprojects { apply plugin: 'eclipse' apply plugin: 'idea' // This allows you to "Build and run using IntelliJ IDEA", an option in IDEA's Settings. idea { module { outputDir = file('build/classes/java/main') testOutputDir = file('build/classes/java/test') } } } configure(subprojects) { apply plugin: 'java-library' apply plugin: 'com.diffplug.spotless' java { toolchain { languageVersion = JavaLanguageVersion.of(24) } } java.sourceCompatibility = 24 // Spotless code formatting spotless { java { eclipse() target '**/src/**/*.java' } } // Lombok configuration dependencies { compileOnly 'org.projectlombok:lombok:1.18.42' compileOnly 'jakarta.annotation:jakarta.annotation-api:2.1.1' annotationProcessor 'org.projectlombok:lombok:1.18.42' testCompileOnly 'org.projectlombok:lombok:1.18.42' testAnnotationProcessor 'org.projectlombok:lombok:1.18.42' // JUnit 5 + Mockito testing testImplementation platform('org.junit:junit-bom:5.14.2') testImplementation 'org.junit.jupiter:junit-jupiter' testRuntimeOnly 'org.junit.platform:junit-platform-launcher' testImplementation 'org.mockito:mockito-core:5.8.0' testImplementation 'org.mockito:mockito-junit-jupiter:5.8.0' } test { testLogging { events 'passed', 'skipped', 'failed' } useJUnitPlatform() jvmArgs '-Dnet.bytebuddy.experimental=true' } // From https://lyze.dev/2021/04/29/libGDX-Internal-Assets-List/ // The article can be helpful when using assets.txt in your project. tasks.register('generateAssetList') { inputs.dir("${project.rootDir}/assets/") // projectFolder/assets File assetsFolder = new File("${project.rootDir}/assets/") // projectFolder/assets/assets.txt File assetsFile = new File(assetsFolder, "assets.txt") // delete that file in case we've already created it assetsFile.delete() // iterate through all files inside that folder // convert it to a relative path // and append it to the file assets.txt fileTree(assetsFolder).collect { assetsFolder.relativePath(it) }.sort().each { assetsFile.append(it + "\n") } } processResources.dependsOn 'generateAssetList' compileJava { options.incremental = true } } subprojects { version = "$projectVersion" ext.appName = 'The Abstraction Engine' repositories { mavenCentral() // You may want to remove the following line if you have errors downloading dependencies. mavenLocal() maven { url = 'https://central.sonatype.com/repository/maven-snapshots/' } maven { url = 'https://jitpack.io' } } } eclipse.project.name = 'The Abstraction Engine' + '-parent'