I’m upgrading my gradle from 6.8.2 to 7.1.1. The checkstyle plugin no longer supports configDir
which requires a file parameter. It is now changed to configDirectory
which needs a directoryProperty
as parameter.
Gradle -6 build.gradle
String path = "abc/xyz"
checkstyle {
configDir file(path)
}
Now in Gradle - 7.1.1 build.gradle
String path = "abc/xyz"
checkstyle {
configDirectory file(path)
}
This is giving me an error while building:
Could not find method configDirectory() for arguments […path…] on extension ‘checkstyle’ of type org.gradle.api.plugins.quality.CheckstyleExtension.