We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
https://docs.gradle.org/7.5.1/userguide/configuration_cache.html
The text was updated successfully, but these errors were encountered:
build: 统一复合构建的gradle.properties文件
38d1737
保持一致,否则gradle configuration cache会因为多次加载这个文件, 认为useAndroidX属性在变化。 Tencent#1120
build: 避免在task执行时调用project接口
f97fc82
invocation of 'Task.project' at execution time is unsupported. Tencent#1120
build: 升级Gradle版本到7.6
d11ea67
为解决configuration cache在复合构建中存在到bug。 升级后执行了`./gradlew wrapper`命令覆盖修改了相关文件。 gradle/gradle#21467 Tencent#1120
虽然这是个一句话需求,但我对Gradle这个新特性还是比较感兴趣,所以看了看。
configuration cache对于Shadow这种模块特别多的项目提高构建速度是非常有用的,每次构建能节约最多20秒的样子。
这个特性目前还处于预览状态,特别是对于复合构建场景有bug。所以要升级Gradle版本。
升级Gradle版本会连带升级编译期环境中的kotlin版本,因为Gradle打包了它。那就需要升级kotlin版本。升级kotlin版本影响就比较大了。还要改动很多代码。
另外从 https://kotlinlang.org/docs/gradle-configure-project.html 可以看到kotlin的gradle插件最高只完整支持gradle到7.1.1版本。但是7.1.1版本的configuration cache特性还有bug。而且kotlin到gradle插件本身也需要适配configuration cache。而且似乎在复合构建场景上还是有bug。
因此目前来看,Shadow项目要想利用上configuration cache特性还比较困难。
如果有同学愿意尝试这个特性,欢迎交流。
Sorry, something went wrong.
No branches or pull requests
https://docs.gradle.org/7.5.1/userguide/configuration_cache.html
The text was updated successfully, but these errors were encountered: