diff --git a/README.md b/README.md index cb51f34..fce632e 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ Add it in your root build.gradle at the end of repositories: -``` +```groovy allprojects { repositories { ... @@ -19,9 +19,9 @@ allprojects { Add the dependency -``` +```groovy dependencies { - implementation 'com.github.zeropercenthappy:RetrofitUtils:1.1.1' + implementation 'com.github.zeropercenthappy:RetrofitUtils:1.1.2' } ``` @@ -50,6 +50,10 @@ val retrofit = RetrofitBuilder() .addConverterFactory(GsonConverterFactory.create()) // option: if you have call adapter to add .addCallAdapterFactory(yourCallAdapter) + // ootion: if you want to modify okhttp builder + .okhttpClientBuilderOption { okhttpBuilder -> + + } .build(context) val api =retrofit.create(Api::class.java) ``` diff --git a/README_CN.md b/README_CN.md index 6ce22ef..b569aa2 100644 --- a/README_CN.md +++ b/README_CN.md @@ -6,7 +6,7 @@ 添加以下配置到你项目根目录的`build.gradle` -``` +```groovy allprojects { repositories { ... @@ -19,9 +19,9 @@ allprojects { 在你项目module中的`build.gradle`中添加依赖 -``` +```groovy dependencies { - implementation 'com.github.zeropercenthappy:RetrofitUtils:1.1.1' + implementation 'com.github.zeropercenthappy:RetrofitUtils:1.1.2' } ``` @@ -50,6 +50,10 @@ val retrofit = RetrofitBuilder() .addConverterFactory(GsonConverterFactory.create()) // 可选: 如果你有CallAdapter要添加 .addCallAdapterFactory(yourCallAdapter) + // 可选: 如果你想修改okhttp builder + .okhttpClientBuilderOption { okhttpBuilder -> + + } .build(context) val api =retrofit.create(Api::class.java) ``` diff --git a/retrofitLib/build.gradle b/retrofitLib/build.gradle index 2e0801e..47d827f 100644 --- a/retrofitLib/build.gradle +++ b/retrofitLib/build.gradle @@ -10,8 +10,8 @@ android { defaultConfig { minSdkVersion 14 targetSdkVersion 28 - versionCode 111 - versionName "1.1.1" + versionCode 112 + versionName "1.1.2" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"