apply from: '../config.gradle'
sourceCompatibility = 1.8
targetCompatibility = 1.8
jar {
    String buildDir = project.buildDir
    manifest {
        attributes(
                'Main-Class': 'com.dounine.japi.JapiClient',
                "Class-Path": new File(buildDir+'/libs/lib').list().collect { "lib/${it}" }.join(" ")
        )

    }
}
task copyJars(type:Copy) {
    from configurations.runtime
    into new File('build/libs/lib') // 目标位置
}
compileJava.dependsOn copyJars
dependencies {
    compile project(":api")

    compile group: 'com.alibaba', name: 'fastjson', version: '1.2.23'
    compile group: 'org.slf4j', name: 'slf4j-log4j12', version: '1.7.22'
    // https://mvnrepository.com/artifact/org.hibernate/hibernate-validator
    compile group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.5.2'
    compile group: 'org.apache.httpcomponents', name: 'httpmime', version: '4.5.2'
    // https://mvnrepository.com/artifact/javax.servlet/javax.servlet-api
    compile group: 'javax.servlet', name: 'javax.servlet-api', version: '3.1.0'
    // https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient
    compile group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.5.3'
// https://mvnrepository.com/artifact/commons-codec/commons-codec
    compile group: 'commons-codec', name: 'commons-codec', version: '1.10'

}


