我正在创建一个使用Kotlin的Squash SQL库的项目。我已经将依赖项添加到了build.gradle文件中。运行更新时,它只是完成而不会输出任何错误。但是该库没有导入到我的项目中,也根本没有出现。

IntelliJ中显示的依赖项:

java - Gradle不会导入Bintray依赖项,但不会引发任何错误-LMLPHP

我的build.gradle文件:

//Kotlin Stuff, nothing changed here

repositories {
    mavenCentral()
    maven {
        url  "http://dl.bintray.com/kotlin/squash"
    }
}

dependencies {
    compile "org.jetbrains.kotlin:kotlin-stdlib-jre8:$kotlin_version"
    testCompile group: 'junit', name: 'junit', version: '4.12'
    compile 'org.jetbrains.squash:squash:0.2.2'
}

//Kotlin Stuff

最佳答案

您添加的依赖项只是在回购中没有任何jar的父pom。这是squash项目(http://dl.bintray.com/kotlin/squash/org/jetbrains/squash/)的列表:

  • squash-core
  • squash-graph
  • squash-h2
  • squash-jdbc
  • squash-postgres
  • squash-sqlite

  • 我想您想导入squash-core以便更改
    compile 'org.jetbrains.squash:squash:0.2.2'
    


    compile 'org.jetbrains.squash:squash-core:0.2.2'
    

    07-24 13:16