[英]How to include dependencies when publish the library to bintray in android
I'm new to publish own library in android. 我是新手在android上发布自己的库。 I created my own library and uploaded it to bintray.
我创建了自己的库并将其上传到bintray。 My library depends several third party libraries.
我的图书馆依赖几个第三方图书馆。 When I see pom.xml file, there are dependency information.
当我看到pom.xml文件时,有依赖信息。 But when I add my library to test project gradle, it didn't import its dependencies.
但是当我添加我的库来测试项目gradle时,它没有导入它的依赖项。 So I had to add it manually test project's gradle.
所以我不得不手动添加它测试项目的gradle。 How can I import dependency module automatically when I add my library to test project's gradle?
当我将库添加到测试项目的gradle时,如何自动导入依赖模块? Is there anyone that can solve this?
有没有人可以解决这个问题? My library is on binary's maven repository.
我的库位于二进制的maven存储库中。 I find expert in this scope now.
我现在在这个范围内找到专家。
You need to include your library as a transitive dependency . 您需要将库包含为传递依赖项 。 Your
build.gradle
should have something like this: 你的
build.gradle
应该是这样的:
compile('com.example.your.library:0.1.0@aar') {
transitive = true;
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.