Netbeans没有使用jitpack获取JAR依赖项的正确版本

时间:2016-03-11 11:23:37

标签: java netbeans github jar jitpack

client的此构建文件使用jitpack指定librarydev版本:

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

mainClassName = 'net.bounceme.mordor.hello.client.HelloClient'

sourceCompatibility = '1.8'
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
if (!hasProperty(mainClassName)) {
    ext.mainClass = mainClassName
}

repositories {
    mavenCentral()
    maven { url "https://jitpack.io" }
}

dependencies {
    testCompile group: 'junit', name: 'junit', version: '4.10'
    compile 'com.github.THUFIR:hello_api:dev'
}

jar {
    manifest {
        attributes ('Main-Class': mainClassName,
            "Class-Path": configurations.compile.collect { it.getName() }.join(' '))
    }
}

assemble.dependsOn (jar)

configurations.all {
    resolutionStrategy.cacheChangingModulesFor 0, 'seconds'
}

然而Netbeans显示hello_api-latest.jar而不是hello_api-dev.jar应该:

enter image description here

0 个答案:

没有答案