Skip to content
This repository has been archived by the owner on Feb 11, 2022. It is now read-only.

Commit

Permalink
Merge pull request #180 from novoda/fix_findbugs_configuration_2
Browse files Browse the repository at this point in the history
Fix Findbugs configuration (part 2)
  • Loading branch information
mr-archano authored Mar 9, 2019
2 parents 661dbfe + e93379f commit 383f983
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,14 @@ class FindbugsConfigurator extends CodeQualityConfigurator<FindBugs, FindBugsExt
}

private FileCollection getJavaClasses(SourceSet sourceSet, List<String> includes) {
includes.isEmpty() ? project.files() : createClassesTreeFrom(sourceSet).include(includes) as ConfigurableFileTree
includes.isEmpty() ? project.files() : createClassesTreeFrom(sourceSet, includes)
}

private ConfigurableFileTree createClassesTreeFrom(SourceSet sourceSet) {
return sourceSet.output.classesDirs.inject(null) { cumulativeTree, classesDir ->
def tree = project.fileTree(classesDir).builtBy(sourceSet.output)
private FileCollection createClassesTreeFrom(SourceSet sourceSet, List<String> includes) {
return sourceSet.output.classesDirs.inject(null) { ConfigurableFileTree cumulativeTree, File classesDir ->
def tree = project.fileTree(classesDir)
.builtBy(sourceSet.output)
.include(includes) as ConfigurableFileTree
cumulativeTree?.plus(tree) ?: tree
}
}
Expand Down
4 changes: 2 additions & 2 deletions sample-multi-module/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ subprojects {
}
}

wrapper {
gradleVersion = '4.10.2'
tasks.wrapper {
gradleVersion = '5.2.1'
distributionType = Wrapper.DistributionType.ALL
}
Binary file modified sample-multi-module/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-5.2.1-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
2 changes: 1 addition & 1 deletion sample-multi-module/gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`

# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""
DEFAULT_JVM_OPTS='"-Xmx64m"'

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
Expand Down
2 changes: 1 addition & 1 deletion sample-multi-module/gradlew.bat
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%

@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=
set DEFAULT_JVM_OPTS="-Xmx64m"

@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
Expand Down
4 changes: 2 additions & 2 deletions sample/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ subprojects {
}
}

wrapper {
gradleVersion = '4.10.2'
tasks.wrapper {
gradleVersion = '5.2.1'
distributionType = Wrapper.DistributionType.ALL
}
Binary file modified sample/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion sample/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-5.2.1-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
2 changes: 1 addition & 1 deletion sample/gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`

# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""
DEFAULT_JVM_OPTS='"-Xmx64m"'

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
Expand Down
2 changes: 1 addition & 1 deletion sample/gradlew.bat
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%

@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=
set DEFAULT_JVM_OPTS="-Xmx64m"

@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
Expand Down

0 comments on commit 383f983

Please sign in to comment.