如何在 Github 上创建库并通过 Android Studio 中的 gradle 依赖项使用它
问题描述:
我想创建库并可以通过 Internet 访问它.在 Android Studio(通过 Gradle)中可以通过这种方式添加依赖项:
I want to create the library and have access to it through the Internet. In Android Studio (via Gradle) dependency may be added in this way:
在build.gradle
(模块应用)中:
dependencies {
...
compile 'com.android.support:design:23.1.0'
compile 'com.squareup:otto:1.3.8'
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'com.j256.ormlite:ormlite-core:4.48'
compile 'com.j256.ormlite:ormlite-android:4.48'
...
}
如何从github以这种方式添加我自己的库?
How can I add my own library in this way from github?
答
Refer Jitpack 最好导入你的项目或者从 Github
到 gradle
Refer Jitpack is best to import your project or libs from Github
to gradle
有关详细信息,请参阅 Gabriele Mariotti 答案
For more information refer Gabriele Mariotti answer