Fix build performance issues of spotless tasks (#722)

Using more efficient glob expressions and removing `targetExclude()` greatly speeds up performance on some OSes.
This commit is contained in:
translatenix
2024-10-21 17:23:40 -07:00
committed by GitHub
parent 9abf1de7de
commit 5057bb5b17
2 changed files with 8 additions and 7 deletions
@@ -42,12 +42,12 @@ artifacts {
spotless {
java {
googleJavaFormat(libs.versions.googleJavaFormat.get())
targetExclude("**/generated/**", "**/build/**")
target("src/*/java/**/*.java")
licenseHeaderFile(rootProject.file("buildSrc/src/main/resources/license-header.star-block.txt"))
}
kotlin {
ktfmt(libs.versions.ktfmt.get()).googleStyle()
targetExclude("**/generated/**", "**/build/**")
target("src/*/kotlin/**/*.kt")
licenseHeaderFile(rootProject.file("buildSrc/src/main/resources/license-header.star-block.txt"))
}
}