plugins {
    id 'org.jetbrains.kotlin.jvm' version '1.5.31'
    id 'org.jetbrains.kotlin.plugin.spring' version '1.5.31'
    id 'org.springframework.boot' version '2.5.5'
    id 'io.spring.dependency-management' version '1.0.11.RELEASE'
}

group 'org.mosad'
version '1.2.7'

repositories {
    mavenCentral()
}

dependencies {
    implementation 'org.springframework.boot:spring-boot-starter-web'
    implementation 'org.jetbrains.kotlin:kotlin-stdlib'
    implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.2'
    implementation 'org.jsoup:jsoup:1.14.3'
    implementation 'com.google.code.gson:gson:2.8.8'

    testImplementation 'org.junit.jupiter:junit-jupiter:5.8.1'
}

test {
    useJUnitPlatform()

    testLogging {
        events 'PASSED', 'FAILED', 'SKIPPED'
    }
}

def jvmTargetVersion = "11"
compileKotlin {
    kotlinOptions.jvmTarget = jvmTargetVersion
    kotlinOptions.freeCompilerArgs += "-Xopt-in=kotlin.RequiresOptIn"
}
compileJava {
    targetCompatibility = jvmTargetVersion
}
compileTestKotlin {
    kotlinOptions.jvmTarget = jvmTargetVersion
}
compileTestJava {
    targetCompatibility = jvmTargetVersion
}