Minestom/code-generators/build.gradle

45 lines
1.4 KiB
Groovy
Raw Normal View History

plugins {
id 'java'
id 'application'
// Used to download our data
}
group 'net.minestom.server'
version '1.0'
sourceCompatibility = 1.11
application {
mainClass.set("net.minestom.codegen.Generators")
}
2021-06-17 12:23:16 +02:00
repositories {
2021-06-18 20:06:29 +02:00
//maven { url "https://repo.minestom.net/repository/maven-public/" }
2021-06-17 12:23:16 +02:00
}
dependencies {
implementation 'com.google.code.gson:gson:2.8.6'
implementation 'org.jetbrains:annotations:20.1.0'
implementation 'com.squareup:javapoet:1.13.0'
// Logging
implementation 'org.apache.logging.log4j:log4j-core:2.14.0'
// SLF4J is the base logger for most libraries, therefore we can hook it into log4j2.
implementation 'org.apache.logging.log4j:log4j-slf4j-impl:2.14.0'
// This is the data Minestom uses. from https://github.com/Minestom/MinestomDataGenerator
2021-06-18 20:06:29 +02:00
//implementation "net.minestom:minestom-data-full:${rootProject.properties.get("mcVersion")}"
}
run {
// Update version
setArgs(List.of(
// Point to gradle.properties "mcVersion"
rootProject.properties.get("mcVersion"),
// If the source is 'classes' it will load from the dependency "net.minestom:minestom-data-customizable:version"
"resources",
// Points to src/autogenerated/java
project.rootProject.projectDir.getPath() + "${File.separatorChar}src${File.separatorChar}autogenerated${File.separatorChar}java"
) as List<String>
)
2021-06-06 04:48:43 +02:00
}