Skip to content

Commit

Permalink
OkHttp extension - Improved configuration
Browse files Browse the repository at this point in the history
- Upgrade to latest version
- Use api dependency, since application code that uses the
  extension more has to use OkHttp directly to make an
  OkHttpClient instance
- Add proguard configuration

Issue #4059

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=191422594
  • Loading branch information
ojw28 committed Apr 3, 2018
1 parent 5f03c37 commit c861b50
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
3 changes: 2 additions & 1 deletion extensions/okhttp/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ android {
defaultConfig {
minSdkVersion project.ext.minSdkVersion
targetSdkVersion project.ext.targetSdkVersion
consumerProguardFiles 'proguard-rules.txt'
}

lintOptions {
Expand All @@ -32,7 +33,7 @@ android {
dependencies {
implementation project(modulePrefix + 'library-core')
implementation 'com.android.support:support-annotations:' + supportLibraryVersion
implementation('com.squareup.okhttp3:okhttp:3.9.0') {
api('com.squareup.okhttp3:okhttp:3.10.0') {
exclude group: 'org.json'
}
}
Expand Down
8 changes: 8 additions & 0 deletions extensions/okhttp/proguard-rules.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Proguard rules specific to the OkHttp extension.

# Options specified by https://github.com/square/okhttp/blob/master/README.md
-dontwarn okhttp3.**
-dontwarn okio.**
-dontwarn javax.annotation.**
-dontwarn org.conscrypt.**
-keepnames class okhttp3.internal.publicsuffix.PublicSuffixDatabase

0 comments on commit c861b50

Please sign in to comment.