Gradle 在我的项目中包含第 3 方依赖项
Gradle include a 3rd party dependency in my project
我有这个项目:https://github.com/TomGrill/gdx-facebook/ and people who want to use it must manually add a 3rd party dependency to their build.gradle file. (https://github.com/TomGrill/gdx-facebook/wiki/3.-Setup-gdx-facebook)
像这样:
compile "de.tomgrill.gdxfacebook:gdx-facebook-android:1.0.0"
compile "com.facebook.android:facebook-android-sdk:4.7.0" //3rd party project
我要的只有这一行:
compile "de.tomgrill.gdxfacebook:gdx-facebook-android:1.0.0"
(1) 因此,当有人将依赖项 (gdx-facebook) 广告到他的 build.gradle 时,将通过 gradle 自动获取第 3 方项目 (android-sdk) .
或
(2) 如何将第 3 方项目包含到我的项目中,以便在我发布时它会自动 compiled/delivered 与我的项目一起。
在您的模块中 gdx-facebook-android
只需添加依赖项:
dependencies {
compile "com.facebook.android:facebook-android-sdk:4.7.0"
}
这样 pom file 将包含依赖项(作为当前的 gdx-facebook-core 模块)
我有这个项目:https://github.com/TomGrill/gdx-facebook/ and people who want to use it must manually add a 3rd party dependency to their build.gradle file. (https://github.com/TomGrill/gdx-facebook/wiki/3.-Setup-gdx-facebook)
像这样:
compile "de.tomgrill.gdxfacebook:gdx-facebook-android:1.0.0"
compile "com.facebook.android:facebook-android-sdk:4.7.0" //3rd party project
我要的只有这一行:
compile "de.tomgrill.gdxfacebook:gdx-facebook-android:1.0.0"
(1) 因此,当有人将依赖项 (gdx-facebook) 广告到他的 build.gradle 时,将通过 gradle 自动获取第 3 方项目 (android-sdk) .
或
(2) 如何将第 3 方项目包含到我的项目中,以便在我发布时它会自动 compiled/delivered 与我的项目一起。
在您的模块中 gdx-facebook-android
只需添加依赖项:
dependencies {
compile "com.facebook.android:facebook-android-sdk:4.7.0"
}
这样 pom file 将包含依赖项(作为当前的 gdx-facebook-core 模块)