plugins {
    application
}

dependencies {
    // Provides the input JSON to generate from
    implementation(libs.minestomData)

    // Common
    implementation(libs.jetbrainsAnnotations)
    implementation(libs.slf4j)
    runtimeOnly(libs.bundles.logback)

    // Parsing and generation
    implementation(libs.gson)
    implementation(libs.javaPoet)
}

tasks {

    application {
        mainClass.set("net.minestom.codegen.Generators")
    }

    getByName<JavaExec>("run") {
        args = listOf(rootProject.projectDir.resolve("src/autogenerated/java").absolutePath)
    }
}
