Skip to content

Commit 85d71c6

Browse files
committed
2021-02-05 Version 1.0.0: Updated build config
1 parent 15e0d1e commit 85d71c6

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

build.gradle

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,13 @@ checkstyle {
1414

1515
def checkstyleConfigPath = "$rootDir/checkstyle.xml"
1616
def checkstyleConfig = new File(checkstyleConfigPath)
17-
new URL(
18-
"https://raw.githubusercontent.com/fartem/repository-rules/master/rules/java/checkstyle/checkstyle.xml"
19-
).withInputStream {
20-
i -> checkstyleConfig.withOutputStream {
21-
it << i
17+
if (!checkstyleConfig.exists()) {
18+
new URL(
19+
"https://raw.githubusercontent.com/fartem/repository-rules/master/rules/java/checkstyle/checkstyle.xml"
20+
).withInputStream {
21+
i -> checkstyleConfig.withOutputStream {
22+
it << i
23+
}
2224
}
2325
}
2426

0 commit comments

Comments
 (0)