File tree 4 files changed +12
-16
lines changed
4 files changed +12
-16
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ artifactIdGradle=spotless-plugin-gradle
21
21
22
22
# Build requirements
23
23
VER_JAVA =11
24
- VER_SPOTBUGS =4.7.3
25
24
VER_JSR_305 =3.0.2
26
25
27
26
# Dependencies provided by Spotless plugin
Original file line number Diff line number Diff line change @@ -14,11 +14,14 @@ tasks.withType(JavaCompile).configureEach {
14
14
// ////////////
15
15
apply plugin : ' com.github.spotbugs'
16
16
spotbugs {
17
- toolVersion = VER_SPOTBUGS
18
17
ignoreFailures = false // bug free or it doesn't ship!
19
18
reportLevel = ' medium' // low|medium|high (low = sensitive to even minor mistakes)
20
19
omitVisitors = [
21
- ' FindReturnRef' ] // https://spotbugs.readthedocs.io/en/latest/detectors.html#findreturnref
20
+ // https://spotbugs.readthedocs.io/en/latest/detectors.html#constructorthrow
21
+ ' ConstructorThrow' ,
22
+ // https://spotbugs.readthedocs.io/en/latest/detectors.html#findreturnref
23
+ ' FindReturnRef' ,
24
+ ]
22
25
}
23
26
tasks. named(' spotbugsTest' ) {
24
27
enabled = false
@@ -30,16 +33,10 @@ tasks.withType(com.github.spotbugs.snom.SpotBugsTask).configureEach {
30
33
reports {
31
34
html. enabled = true
32
35
}
33
- notCompatibleWithConfigurationCache(" https://github.com/spotbugs/spotbugs-gradle-plugin/issues/670" )
34
36
}
35
37
36
- tasks. named(' spotbugsMain' ) {
37
- reports {
38
- html. enabled = true
39
- }
40
- }
41
38
dependencies {
42
39
compileOnly ' net.jcip:jcip-annotations:1.0'
43
- compileOnly " com.github.spotbugs:spotbugs-annotations:${ VER_SPOTBUGS } "
40
+ compileOnly " com.github.spotbugs:spotbugs-annotations:${ spotbugs.toolVersion.get() } "
44
41
compileOnly " com.google.code.findbugs:jsr305:${ VER_JSR_305} "
45
42
}
Original file line number Diff line number Diff line change @@ -56,16 +56,16 @@ for (needsP2 in NEEDS_P2_DEPS) {
56
56
add(" ${ needsP2} CompileOnly" , " dev.equo.ide:solstice:${ VER_SOLSTICE} " )
57
57
}
58
58
}
59
- jar {
59
+
60
+ def jar = tasks. named(' jar' , Jar ) {
60
61
for (needsP2 in NEEDS_P2_DEPS ) {
61
- from sourceSets. getByName (needsP2). output. classesDirs
62
+ from sourceSets. named (needsP2). map { it . output. classesDirs }
62
63
}
63
64
}
65
+
64
66
tasks. withType(Test ). configureEach {
65
67
dependsOn jar
66
- doFirst {
67
- classpath + = jar. outputs. files
68
- }
68
+ classpath + = jar. get(). outputs. files
69
69
}
70
70
71
71
apply plugin : ' dev.equo.p2deps'
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ plugins {
12
12
// https://github.com/gradle-nexus/publish-plugin/releases
13
13
id ' io.github.gradle-nexus.publish-plugin' version ' 1.3.0' apply false
14
14
// https://github.com/spotbugs/spotbugs-gradle-plugin/releases
15
- id ' com.github.spotbugs' version ' 5.2.1 ' apply false
15
+ id ' com.github.spotbugs' version ' 5.2.3 ' apply false
16
16
// https://github.com/diffplug/spotless-changelog/blob/main/CHANGELOG.md
17
17
id ' com.diffplug.spotless-changelog' version ' 3.0.2' apply false
18
18
// https://github.com/diffplug/goomph/blob/main/CHANGES.md
You can’t perform that action at this time.
0 commit comments