Skip to content

Instantly share code, notes, and snippets.

@STAR-ZERO
Last active May 2, 2018 06:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save STAR-ZERO/4c98b0decd6eee1c020e9912ed2963a0 to your computer and use it in GitHub Desktop.
Save STAR-ZERO/4c98b0decd6eee1c020e9912ed2963a0 to your computer and use it in GitHub Desktop.
support libraryのバージョンコンフリクト対応
def supportLibraryVersion = '27.1.1'
android {
// ...
defaultConfig {
// ...
multiDexEnabled true
}
// ...
}
configurations.all { config ->
config.resolutionStrategy {
eachDependency { DependencyResolveDetails details ->
// multidex以外のsupport libraryのバージョン固定
if (details.requested.group == 'com.android.support' && !details.requested.name.contains('multidex')) {
details.useVersion supportLibraryVersion
}
}
}
}
dependencies {
// ...
implementation "com.android.support:appcompat-v7:$supportLibraryVersion"
implementation "com.android.support:design:$supportLibraryVersion"
// ...
debugImplementation 'com.willowtreeapps.hyperion:hyperion-core:0.9.22'
debugImplementation 'com.willowtreeapps.hyperion:hyperion-attr:0.9.22'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment