We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
skipCodeStyle
1 parent 1f4739e commit 73e3278Copy full SHA for 73e3278
gradle/code-style-config.gradle
@@ -36,9 +36,11 @@ extensions.configure(CodeNarcExtension) {
36
}
37
38
// Do not run Code Style checks if the property 'skipCodeStyle' is defined
39
-if (findProperty('skipCodeStyle')) {
40
- tasks.withType(Checkstyle).configureEach { enabled = false }
41
- tasks.withType(CodeNarc).configureEach { enabled = false }
+tasks.withType(Checkstyle).configureEach {
+ onlyIf { !project.hasProperty('skipCodeStyle') }
+}
42
+tasks.withType(CodeNarc).configureEach {
43
44
45
46
tasks.register('codeStyle') {
0 commit comments