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 #218 from novoda/taso/fix-gradle-6-issue
Browse files Browse the repository at this point in the history
Fix Gradle 6 issue
  • Loading branch information
mr-archano authored Nov 22, 2019
2 parents 59e7605 + 69090f3 commit b62c1b2
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package com.novoda.staticanalysis
import com.novoda.staticanalysis.internal.Configurator
import com.novoda.staticanalysis.internal.checkstyle.CheckstyleConfigurator
import com.novoda.staticanalysis.internal.detekt.DetektConfigurator
import com.novoda.staticanalysis.internal.findbugs.FindbugsConfigurator
import com.novoda.staticanalysis.internal.findbugs.FindbugsConfiguratorFactory
import com.novoda.staticanalysis.internal.ktlint.KtlintConfigurator
import com.novoda.staticanalysis.internal.lint.LintConfigurator
import com.novoda.staticanalysis.internal.pmd.PmdConfigurator
Expand Down Expand Up @@ -42,7 +42,7 @@ class StaticAnalysisPlugin implements Plugin<Project> {
[
CheckstyleConfigurator.create(project, violationsContainer, evaluateViolations),
PmdConfigurator.create(project, violationsContainer, evaluateViolations),
FindbugsConfigurator.create(project, violationsContainer, evaluateViolations),
FindbugsConfiguratorFactory.create(project, violationsContainer, evaluateViolations),
SpotBugsConfigurator.create(project, violationsContainer, evaluateViolations),
DetektConfigurator.create(project, violationsContainer, evaluateViolations),
KtlintConfigurator.create(project, violationsContainer, evaluateViolations),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import com.novoda.staticanalysis.Violations
import com.novoda.staticanalysis.internal.CodeQualityConfigurator
import org.gradle.api.Action
import org.gradle.api.DomainObjectSet
import org.gradle.api.NamedDomainObjectContainer
import org.gradle.api.Project
import org.gradle.api.Task
import org.gradle.api.file.FileCollection
Expand All @@ -24,17 +23,7 @@ class FindbugsConfigurator extends CodeQualityConfigurator<FindBugs, FindBugsExt

protected boolean htmlReportEnabled = true

@Deprecated
static FindbugsConfigurator create(Project project,
NamedDomainObjectContainer<Violations> violationsContainer,
Task evaluateViolations) {
Violations violations = violationsContainer.maybeCreate('Findbugs')
return new FindbugsConfigurator(project, violations, evaluateViolations)
}

private FindbugsConfigurator(Project project,
Violations violations,
Task evaluateViolations) {
FindbugsConfigurator(Project project, Violations violations, Task evaluateViolations) {
super(project, violations, evaluateViolations)
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package com.novoda.staticanalysis.internal.findbugs

import com.novoda.staticanalysis.Violations
import org.gradle.api.NamedDomainObjectContainer
import org.gradle.api.Project
import org.gradle.api.Task

@Deprecated
class FindbugsConfiguratorFactory {

private FindbugsConfiguratorFactory() {
}

static FindbugsConfigurator create(Project project,
NamedDomainObjectContainer<Violations> violationsContainer,
Task evaluateViolations) {
Violations violations = violationsContainer.maybeCreate('Findbugs')
return new FindbugsConfigurator(project, violations, evaluateViolations)
}
}

0 comments on commit b62c1b2

Please sign in to comment.