Files
IdleRSC/spotless.gradle
George Rawlinson 556ef99d91 build: use gradle version catalogs
This commit keeps all versions in one location, for reference throughout
various build scripts.

https://docs.gradle.org/current/userguide/platforms.html
2023-03-23 19:55:28 +13:00

23 lines
632 B
Groovy

spotless {
format 'misc', {
// Define the files to apply `misc` to
target '**/*.gradle', '**/*.md', '**/.gitignore'
// Define the steps to apply to those files
trimTrailingWhitespace()
indentWithSpaces(2)
endWithNewline()
}
java {
// Use the default importOrder configuration
importOrder()
// Remove unused imports
removeUnusedImports()
// Follow the Google Java formatting guide
// ref: https://google.github.io/styleguide/javaguide.html
googleJavaFormat("${libs.versions.google.java.format.get()}")
// Fix formatting of type annotations
formatAnnotations()
}
}