version '1.1.1'

buildscript {
    ext.kotlin_version = '1.4.10'

    repositories {
        maven{ url 'https://maven.aliyun.com/nexus/content/groups/public/'}
        mavenLocal()
        mavenCentral()
    }
    dependencies {
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}
apply plugin: 'java'
apply plugin: 'kotlin'

repositories {
    mavenLocal()
    mavenCentral()
}
sourceCompatibility = 1.8
targetCompatibility = 1.8
jar {
    from {
        configurations.compile.collect { it.isDirectory() ? it : zipTree(it) }
    }
    exclude 'META-INF/versions/9/*.class','META-INF/*.txt','META-INF/*/*','META-INF/LICENSE','META-INF/NOTICE'
}
repositories {
    mavenCentral()
}
sourceSets{
    main.kotlin.srcDirs += 'src'
    main.java.srcDirs += 'src'
    test.kotlin.srcDirs += 'test'
    test.java.srcDirs += 'test'
}
dependencies {
    compile 'net.portswigger.burp.extender:burp-extender-api:1.7.13'
    compile group: 'com.google.code.gson', name: 'gson', version: '2.8.9'
    compile 'mysql:mysql-connector-java:8.0.27'
    // https://mvnrepository.com/artifact/com.google.guava/guava
    compile group: 'com.google.guava', name: 'guava', version: '30.1-jre'
    // https://mvnrepository.com/artifact/org.apache.commons/commons-text
    compile group: 'org.apache.commons', name: 'commons-text', version: '1.9'
// https://mvnrepository.com/artifact/org.xerial/sqlite-jdbc
    compile group: 'org.xerial', name: 'sqlite-jdbc', version: '3.36.0.3'
    compile group: 'org.apache.poi', name: 'poi', version: '5.2.3'
    compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
}

test {
    useJUnitPlatform()
}
compileKotlin {
    kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
    kotlinOptions.jvmTarget = "1.8"
}
tasks.withType(JavaCompile) {
    options.encoding = "UTF-8"
}