apply plugin: 'java'
apply plugin: 'application'

group 'com.lostsys.test.javalin'
version '1.0-SNAPSHOT'

mainClassName = 'com.lostsys.test.javalin.Bench'

sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11

repositories {
    mavenCentral()
}

dependencies {
    compile 'io.javalin:javalin:2.8.0'
    compile "com.fasterxml.jackson.core:jackson-databind:2.9.9"
    compile "org.slf4j:slf4j-simple:1.8.0-beta4"
}

//create a single Jar with all dependencies
task fatJar(type: Jar) {
    manifest {
        attributes(
                "Main-Class": mainClassName
        )
    }
    baseName = project.name + '-all'
    from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
    with jar
}
