How to manage different support library versions for 3rd party deps with gradle?

前端 未结 4 591
误落风尘
误落风尘 2020-12-12 19:33

I have a bunch of third party libs that I include in my base application. I cannot control the support library those 3rd party modules include. This makes it hard to have t

4条回答
  •  北海茫月
    2020-12-12 20:03

    First case: You have compatible libs wich already updated their own internal libs, No problem here.

    Second case: You have libs in your project which have higher version than other libs contained internal to other libs, and these libs can be updated to new version with no such problem, Also No problem here.

    Worst case: You have libs in your project which have higher version than other libs contained internal to other libs, and these libs doesn't have a new version that has already updated there internal libs, suggested solutions for that:

    1. Download that library and include it to your app as project implementation project(':library') and update their internal libs.
    2. OR Use other library instead.

    Don't forget to use ./gradlew app:dependencies to check your dependencies.

    Also I believe should be there someway to do that automatically.

提交回复
热议问题