Gradle 构建洞察
Gradle 构建洞察 {#gradle-build-insights}
Section titled “Gradle 构建洞察 {#gradle-build-insights}”::: warning 要求
- 已安装并配置
Tuist Gradle 插件
:::
Tuist 的 Gradle 插件可以向 Tuist 发送构建分析,让你了解任务执行和构建性能。
配置上传行为 {#configure-upload-behavior}
Section titled “配置上传行为 {#configure-upload-behavior}”默认情况下:
- 本地构建会在后台上传构建分析。
- CI 运行会在前台上传构建分析,以避免在短生命周期代理上丢失遥测数据。
你可以使用 tuist 扩展中的 uploadInBackground 来控制此行为:
tuist { uploadInBackground = false // 始终在前台上传}配置参考 {#configuration-reference}
Section titled “配置参考 {#configuration-reference}”uploadInBackground 选项在 settings.gradle.kts 的 tuist 扩展块中可用:
| 选项 | 类型 | 默认值 | 描述 |
|---|---|---|---|
uploadInBackground | Boolean? | null(本地后台,CI 前台) | 是否在后台为本地构建上传构建洞察。 |
此设置不影响 buildCache 块中的远程缓存设置。