Android Studio 查看依赖冲突

释放双眼,带上耳机,听听看~!
./gradlew :app:dependencies --configuration compile

查看依赖冲突

例如:

  • alibaba:arouter 导致的依赖冲突 com.android.support

报错信息

All com.android.support libraries must use the exact same version specification (mixing versions can lead to runtime crashes). Found versions 28.0.0, 25.2.0. Examples include com.android.support:animated-vector-drawable:28.0.0 and com.android.support:support-media-compat:25.2.0
  • 原因版本不一致

解决办法

api ('com.alibaba:arouter-api:1.4.1'){
//exclude group: 'com.android.support'
}

人已赞赏
个人中心
购物车
优惠劵
今日签到
有新私信 私信列表
有新消息 消息中心
搜索