如果存储库缺少任何标记,如何将 git 存储库声明为 gradle 依赖项?
How to declare a git repository as gradle dependency if the repository is missing any tag?
我正在尝试从我的项目中添加对 https://github.com/DaleKocian/VolleyAndRxJava 的依赖,但出现错误:
Error:(130, 13) Failed to resolve: com.github.DaleKocian:VolleyAndRxJava:+
<a href="openFile:/Users/michaelosofsky/Developer/android-sdk-1.2/locuslabs-android-sdk/app/build.gradle">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
我认为问题在于我没有指定正确的标签,而根据指定,Is it possible to declare git repository as dependency in android gradle?.
中需要该标签
不知道用什么标签,因为https://github.com/DaleKocian/VolleyAndRxJava好像没有标签
根据,语法是用 Ivy 指定的,但我无法从 Ivy 文档中得知我应该如何指定没有标签。
这是我的 build.gradle 文件的摘录:
repositories {
mavenCentral()
}
dependencies {
compile 'com.github.DaleKocian:VolleyAndRxJava:+'
}
以下是我为标签尝试的其他值:
'com.github.DaleKocian:VolleyAndRxJava:+'
'com.github.DaleKocian:VolleyAndRxJava:'
'com.github.DaleKocian:VolleyAndRxJava'
'com.github.DaleKocian:VolleyAndRxJava:latest'
'com.github.DaleKocian:VolleyAndRxJava:latest.integration'
'com.github.DaleKocian:VolleyAndRxJava:latest.release'
'compile 'com.github.DaleKocian:VolleyAndRxJava:latest.[any status]'
None 的那些虽然有效,但我应该如何在我的 build.gradle 文件中添加 https://github.com/DaleKocian/VolleyAndRxJava 作为依赖项?
Examples of using rx java with volley
这就是存储库的全部内容。示例。
它本身不是像 Volley 或 RxJava 这样的库。
您可以从您的项目中单独克隆该库,并安装它,运行 一些示例,然后将必要的代码部分复制到您自己的应用程序中。
如果您确实有一个未发布到 BinTray 的库,那么 JitPack 可以允许您使用标签或提交引用
编译 Github 个项目
供参考:https://jitpack.io/#DaleKocian/VolleyAndRxJava
但是,如前所述,它不是图书馆
我正在尝试从我的项目中添加对 https://github.com/DaleKocian/VolleyAndRxJava 的依赖,但出现错误:
Error:(130, 13) Failed to resolve: com.github.DaleKocian:VolleyAndRxJava:+
<a href="openFile:/Users/michaelosofsky/Developer/android-sdk-1.2/locuslabs-android-sdk/app/build.gradle">Show in File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
我认为问题在于我没有指定正确的标签,而根据指定,Is it possible to declare git repository as dependency in android gradle?.
中需要该标签不知道用什么标签,因为https://github.com/DaleKocian/VolleyAndRxJava好像没有标签
根据
这是我的 build.gradle 文件的摘录:
repositories {
mavenCentral()
}
dependencies {
compile 'com.github.DaleKocian:VolleyAndRxJava:+'
}
以下是我为标签尝试的其他值:
'com.github.DaleKocian:VolleyAndRxJava:+'
'com.github.DaleKocian:VolleyAndRxJava:'
'com.github.DaleKocian:VolleyAndRxJava'
'com.github.DaleKocian:VolleyAndRxJava:latest'
'com.github.DaleKocian:VolleyAndRxJava:latest.integration'
'com.github.DaleKocian:VolleyAndRxJava:latest.release'
'compile 'com.github.DaleKocian:VolleyAndRxJava:latest.[any status]'
None 的那些虽然有效,但我应该如何在我的 build.gradle 文件中添加 https://github.com/DaleKocian/VolleyAndRxJava 作为依赖项?
Examples of using rx java with volley
这就是存储库的全部内容。示例。
它本身不是像 Volley 或 RxJava 这样的库。
您可以从您的项目中单独克隆该库,并安装它,运行 一些示例,然后将必要的代码部分复制到您自己的应用程序中。
如果您确实有一个未发布到 BinTray 的库,那么 JitPack 可以允许您使用标签或提交引用
编译 Github 个项目供参考:https://jitpack.io/#DaleKocian/VolleyAndRxJava
但是,如前所述,它不是图书馆