Gradle踩过的坑

2020-12-05  本文已影响0人  肥牛大猛

1.Cannot change attributes of configuration ‘:xxx:yyy’ after it has been resolved

解决方法:检查xxx的gradle.build文件中,是否有使用和主工程有冲出的语法,例如,include要缓存implementation

2.setting.gradle引入library工程

include ':xxx'

project(':xxx').projectDir = new File("D:\\aaa\\bbb")

3.config.gradle

setting.gradle引入,apply from:'config.gradle',ext.xxx[xxx]

gradle.gradle引入,

buildscript {

    apply from:"config.gradle"

    ...

},rootProject.ext.xxx[xxx]

上一篇下一篇

猜你喜欢

热点阅读