本地新建Android Studio項目
-
新建Module,選擇Android library(我的名字是dialog)
image.png -
刪除項目下的app Module装悲,只留Android library
image.png 編寫內(nèi)容 項目中 無需 無需 無需 做任何特殊處理 例如這種
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5'
apply plugin: 'com.github.dcendents.android-maven'
group='com.github.你的guihub的賬戶名字'
- 使用git上傳到github
-
選擇發(fā)布
image.png -
發(fā)布內(nèi)容
image.png - 打開https://jitpack.io/
image.png -
集成進項目
image.png
我的測試項目
GIF.gif
https://github.com/Lrxc/lrxcdialog
添加依賴 參考步驟9
maven { url 'https://jitpack.io' }
compile 'com.github.Lrxc:lrxcdialog:1.2'