Skip to content

Commit

Permalink
Cleanup GradleLint task configurers and fix POM generation
Browse files Browse the repository at this point in the history
  • Loading branch information
rpalcolea committed Feb 3, 2023
1 parent 8f612f5 commit c635e42
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 174 deletions.
6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,9 @@ configurations.all {

dependencies {
compileOnly 'dev.gradleplugins:gradle-api:7.6'
api 'com.netflix.nebula:nebula-gradle-interop:latest.release'
api 'org.apache.maven:maven-model-builder:3.8.3'
api 'org.codehaus.gpars:gpars:1.2.1'
shadow 'com.netflix.nebula:nebula-gradle-interop:latest.release'
shadow 'org.apache.maven:maven-model-builder:3.8.3'
shadow 'org.codehaus.gpars:gpars:1.2.1'
plugin 'com.google.guava:guava:19.0'
plugin('org.ow2.asm:asm:9.+') {
version {
Expand Down
39 changes: 20 additions & 19 deletions gradle.lockfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ com.jcraft:jsch:0.1.54=integTestRuntimeClasspath,testRuntimeClasspath
com.jcraft:jzlib:1.1.2=integTestRuntimeClasspath,testRuntimeClasspath
com.netflix.nebula:gradle-contacts-plugin:7.0.0=integTestRuntimeClasspath,testRuntimeClasspath
com.netflix.nebula:gradle-info-plugin:12.0.0=integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
com.netflix.nebula:nebula-gradle-interop:2.1.1=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
com.netflix.nebula:nebula-gradle-interop:2.0.0=integTestRuntimeClasspath,testRuntimeClasspath
com.netflix.nebula:nebula-gradle-interop:2.1.1=compileClasspath,shadow
com.netflix.nebula:nebula-test:10.3.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
com.perforce:p4java:2015.2.1365273=integTestRuntimeClasspath,testRuntimeClasspath
com.trilead:trilead-ssh2:1.0.0-build220=integTestRuntimeClasspath,testRuntimeClasspath
Expand All @@ -24,41 +25,41 @@ commons-lang:commons-lang:2.6=compileClasspath,runtimeClasspath,testCompileClass
commons-logging:commons-logging:1.2=integTestRuntimeClasspath,testRuntimeClasspath
de.regnis.q.sequence:sequence-library:1.0.3=integTestRuntimeClasspath,testRuntimeClasspath
dev.gradleplugins:gradle-api:7.6=compileClasspath
javax.inject:javax.inject:1=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
javax.inject:javax.inject:1=compileClasspath,shadow
joda-time:joda-time:2.12.2=integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
junit:junit:4.13.2=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
net.java.dev.jna:jna-platform:5.7.0=integTestRuntimeClasspath,testRuntimeClasspath
net.java.dev.jna:jna:5.7.0=integTestRuntimeClasspath,testRuntimeClasspath
net.java.dev.jna:platform:3.4.0=integTestRuntimeClasspath,testRuntimeClasspath
org.antlr:antlr-runtime:3.4=integTestRuntimeClasspath,testRuntimeClasspath
org.apache.commons:commons-lang3:3.8.1=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.apache.commons:commons-lang3:3.8.1=compileClasspath,shadow
org.apache.httpcomponents:httpclient:4.5.2=integTestRuntimeClasspath,testRuntimeClasspath
org.apache.httpcomponents:httpcore:4.4.4=integTestRuntimeClasspath,testRuntimeClasspath
org.apache.maven:maven-artifact:3.8.3=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.apache.maven:maven-builder-support:3.8.3=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.apache.maven:maven-model-builder:3.8.3=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.apache.maven:maven-model:3.8.3=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.apache.maven:maven-artifact:3.8.3=compileClasspath,shadow
org.apache.maven:maven-builder-support:3.8.3=compileClasspath,shadow
org.apache.maven:maven-model-builder:3.8.3=compileClasspath,shadow
org.apache.maven:maven-model:3.8.3=compileClasspath,shadow
org.apiguardian:apiguardian-api:1.1.2=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
org.codehaus.gpars:gpars:1.2.1=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.codehaus.gpars:gpars:1.2.1=compileClasspath,shadow
org.codehaus.groovy:groovy:3.0.13=compileClasspath
org.codehaus.groovy:groovy:3.0.9=integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
org.codehaus.jsr166-mirror:jsr166y:1.7.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.codehaus.plexus:plexus-interpolation:1.26=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.codehaus.plexus:plexus-utils:3.3.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.codehaus.jsr166-mirror:jsr166y:1.7.0=compileClasspath,shadow
org.codehaus.plexus:plexus-interpolation:1.26=compileClasspath,shadow
org.codehaus.plexus:plexus-utils:3.3.0=compileClasspath,shadow
org.codenarc:CodeNarc:2.0.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.eclipse.jdt:core:3.1.1=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.eclipse.jgit:org.eclipse.jgit:5.0.1.201806211838-r=compileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.eclipse.sisu:org.eclipse.sisu.inject:0.3.5=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.eclipse.sisu:org.eclipse.sisu.inject:0.3.5=compileClasspath,shadow
org.hamcrest:hamcrest-core:1.3=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
org.hamcrest:hamcrest:2.2=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
org.jetbrains.kotlin:kotlin-stdlib-common:1.8.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.8.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.jetbrains.kotlin:kotlin-stdlib:1.8.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.jetbrains:annotations:13.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.jetbrains.kotlin:kotlin-stdlib-common:1.8.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,shadow,testCompileClasspath,testRuntimeClasspath
org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.8.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,shadow,testCompileClasspath,testRuntimeClasspath
org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,shadow,testCompileClasspath,testRuntimeClasspath
org.jetbrains.kotlin:kotlin-stdlib:1.8.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,shadow,testCompileClasspath,testRuntimeClasspath
org.jetbrains:annotations:13.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,shadow,testCompileClasspath,testRuntimeClasspath
org.junit.platform:junit-platform-commons:1.8.1=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
org.junit.platform:junit-platform-engine:1.8.1=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
org.multiverse:multiverse-core:0.7.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
org.multiverse:multiverse-core:0.7.0=compileClasspath,shadow
org.objenesis:objenesis:2.4=integTestRuntimeClasspath,testRuntimeClasspath
org.opentest4j:opentest4j:1.2.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
org.ow2.asm:asm-commons:9.4=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
Expand All @@ -72,4 +73,4 @@ org.spockframework:spock-core:2.1-M2-groovy-3.0=compileClasspath,integTestCompil
org.spockframework:spock-junit4:2.1-M2-groovy-3.0=compileClasspath,integTestCompileClasspath,integTestRuntimeClasspath,testCompileClasspath,testRuntimeClasspath
org.tmatesoft.sqljet:sqljet:1.1.10=integTestRuntimeClasspath,testRuntimeClasspath
org.tmatesoft.svnkit:svnkit:1.8.12=integTestRuntimeClasspath,testRuntimeClasspath
empty=annotationProcessor,compile,integTestAnnotationProcessor,integTestCompile,integTestCompileOnly,integTestRuntime,runtime,shadow,testAnnotationProcessor,testCompile,testCompileOnly,testRuntime
empty=annotationProcessor,compile,integTestAnnotationProcessor,integTestCompile,integTestCompileOnly,integTestRuntime,runtime,testAnnotationProcessor,testCompile,testCompileOnly,testRuntime

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.netflix.nebula.lint.plugin

import com.netflix.nebula.interop.GradleKt

import org.gradle.BuildAdapter
import org.gradle.api.BuildCancelledException
import org.gradle.api.Plugin
Expand All @@ -31,15 +31,7 @@ class GradleLintPlugin implements Plugin<Project> {
}

LintRuleRegistry.classLoader = getClass().classLoader

// TODO: we need to retire this once we have folks in Gradle 7.x+
if (GradleKt.versionCompareTo(project.gradle, '7.1') >= 0) {
new Gradle7AndHigherLintPluginTaskConfigurer().configure(project)
} else if (GradleKt.versionCompareTo(project.gradle, '5.0') >= 0) {
new GradleBetween5And7LintPluginTaskConfigurer().configure(project)
} else {
new LegacyGradleLintPluginTaskConfigurer().configure(project)
}
new LintPluginTaskConfigurer().configure(project)
}

protected static abstract class LintListener extends BuildAdapter implements TaskExecutionGraphListener {}
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package com.netflix.nebula.lint.plugin
import org.gradle.api.Action
import org.gradle.api.Project

class Gradle7AndHigherLintPluginTaskConfigurer extends GradleBetween5And7LintPluginTaskConfigurer {
class LintPluginTaskConfigurer extends GradleLintPluginTaskConfigurer {
@Override
Action<GradleLintReportTask> configureReportAction(Project project, GradleLintExtension extension) {
new Action<GradleLintReportTask>() {
Expand Down

0 comments on commit c635e42

Please sign in to comment.