android中的Gradle Gradle的自定义存储库

时间:2018-08-16 11:52:47

标签: android maven gradle

我正在创建Android库模块,其中需要包含一个需要身份验证的依赖项,因此无法与sdk用户共享其用户名和密码。当我在库build.gradle中设置自定义url时,不寻找存储库。 当我将自定义存储库URL放入项目级别gradle时,它可以工作,但不起作用。 代码示例:

图书馆摇篮:

apply plugin: 'com.android.library'

repositories {
    maven {
        url "https://custom.bintray.com"
    }
    maven {
        url "http://custom.bintray.com"
        credentials {
            username 'asfsafasf'
            password 'asdasfsf'
        }
    }
}
dependencies{
    implementation <gradle path of library present in above custom repo>
}

在我的项目中使用库gradle时,无法解析存储库

0 个答案:

没有答案