From 4f4495a501eb2cf09e1f7ee649f8d3648539729a Mon Sep 17 00:00:00 2001 From: Jendrik Johannes Date: Wed, 8 Jan 2020 12:43:06 +0100 Subject: [PATCH] Use 'java-library' plugin component for publishing instead of War plugin --- .../gradle/plugins/jpi/JpiHplManifest.groovy | 11 +- .../gradle/plugins/jpi/JpiPlugin.groovy | 106 +++++------------- .../plugins/jpi/JpiPomCustomizer.groovy | 63 +---------- .../plugins/jpi/JpiHplManifestSpec.groovy | 1 - .../plugins/jpi/JpiIntegrationSpec.groovy | 3 +- .../gradle/plugins/jpi/JpiPluginSpec.groovy | 5 - .../JpiPomCustomizerIntegrationSpec.groovy | 9 +- .../plugins/jpi/compile-dependencies-pom.xml | 13 ++- ...compile-dependencies-with-excludes-pom.xml | 15 +-- .../jpi/optional-plugin-dependencies-pom.xml | 13 ++- .../plugins/jpi/plugin-dependencies-pom.xml | 13 ++- 11 files changed, 74 insertions(+), 178 deletions(-) diff --git a/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiHplManifest.groovy b/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiHplManifest.groovy index 5f7af4fb..2e4eff0f 100644 --- a/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiHplManifest.groovy +++ b/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiHplManifest.groovy @@ -16,9 +16,6 @@ package org.jenkinsci.gradle.plugins.jpi import org.gradle.api.Project -import org.gradle.api.plugins.WarPlugin -import org.gradle.api.plugins.WarPluginConvention -import org.gradle.api.tasks.bundling.War /** * @author Kohsuke Kawaguchi @@ -27,15 +24,13 @@ class JpiHplManifest extends JpiManifest { JpiHplManifest(Project project) { super(project) - def conv = project.extensions.getByType(JpiExtension) - War war = project.tasks.getByName(WarPlugin.WAR_TASK_NAME) as War + def jpiExtension = project.extensions.getByType(JpiExtension) // src/main/webApp - def warconv = project.convention.getPlugin(WarPluginConvention) - mainAttributes.putValue('Resource-Path', warconv.webAppDir.absolutePath) + mainAttributes.putValue('Resource-Path', project.file(JpiPlugin.WEB_APP_DIR).absolutePath) // add resource directories directly so that we can pick up the source, then add all the jars and class path - Set libraries = conv.mainSourceTree().resources.srcDirs + war.classpath.files + Set libraries = jpiExtension.mainSourceTree().output.files mainAttributes.putValue('Libraries', libraries.findAll { it.exists() }.join(',')) } } diff --git a/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPlugin.groovy b/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPlugin.groovy index 2db99a07..5b531944 100644 --- a/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPlugin.groovy +++ b/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPlugin.groovy @@ -18,16 +18,16 @@ package org.jenkinsci.gradle.plugins.jpi import org.gradle.api.GradleException import org.gradle.api.Plugin import org.gradle.api.Project -import org.gradle.api.Task import org.gradle.api.artifacts.Configuration import org.gradle.api.artifacts.ConfigurationContainer import org.gradle.api.artifacts.Dependency import org.gradle.api.artifacts.ResolvedArtifact import org.gradle.api.execution.TaskExecutionGraph import org.gradle.api.plugins.BasePlugin +import org.gradle.api.plugins.JavaLibraryPlugin import org.gradle.api.plugins.JavaPlugin import org.gradle.api.plugins.JavaPluginConvention -import org.gradle.api.plugins.WarPlugin +import org.gradle.api.plugins.JavaPluginExtension import org.gradle.api.plugins.GroovyPlugin import org.gradle.api.publish.PublishingExtension import org.gradle.api.publish.maven.MavenPublication @@ -40,12 +40,11 @@ import org.gradle.api.tasks.bundling.War import org.gradle.api.tasks.compile.GroovyCompile import org.gradle.api.tasks.compile.JavaCompile import org.gradle.api.tasks.testing.Test -import org.gradle.util.GradleVersion import static org.gradle.api.logging.LogLevel.INFO +import static org.gradle.api.plugins.JavaPlugin.API_CONFIGURATION_NAME +import static org.gradle.api.plugins.JavaPlugin.COMPILE_ONLY_CONFIGURATION_NAME import static org.gradle.api.plugins.JavaPlugin.TEST_IMPLEMENTATION_CONFIGURATION_NAME -import static org.gradle.api.plugins.WarPlugin.PROVIDED_COMPILE_CONFIGURATION_NAME -import static org.gradle.api.plugins.WarPlugin.PROVIDED_RUNTIME_CONFIGURATION_NAME import static org.gradle.api.tasks.SourceSet.MAIN_SOURCE_SET_NAME import static org.gradle.api.tasks.SourceSet.TEST_SOURCE_SET_NAME import static org.jenkinsci.gradle.plugins.jpi.JpiManifest.attributesToMap @@ -91,13 +90,11 @@ class JpiPlugin implements Plugin { public static final String JENKINS_SERVER_DEPENDENCY_CONFIGURATION_NAME = 'jenkinsServer' public static final String JPI_TASK_NAME = 'jpi' - public static final String SOURCES_JAR_TASK_NAME = 'sourcesJar' - public static final String JAVADOC_JAR_TASK_NAME = 'javadocJar' public static final String LICENSE_TASK_NAME = 'generateLicenseInfo' + public static final String WEB_APP_DIR = "src/main/webapp" void apply(final Project gradleProject) { - gradleProject.plugins.apply(JavaPlugin) - gradleProject.plugins.apply(WarPlugin) + gradleProject.plugins.apply(JavaLibraryPlugin) gradleProject.plugins.apply(GroovyPlugin) def ext = gradleProject.extensions.create('jenkinsPlugin', JpiExtension, gradleProject) @@ -114,29 +111,11 @@ class JpiPlugin implements Plugin { } configureLocalizer(gradleProject) - configureLicenseInfo(gradleProject) configureInjectedTest(gradleProject) - gradleProject.tasks.register(SOURCES_JAR_TASK_NAME, Jar) { - it.dependsOn('classes') - def classifier = 'sources' - if (GradleVersion.current() >= GradleVersion.version('5.1')) { - it.archiveClassifier.set(classifier) - } else { - it.classifier = classifier - } - it.from gradleProject.sourceSets.main.allSource - } - gradleProject.tasks.register(JAVADOC_JAR_TASK_NAME, Jar) { - it.dependsOn('javadoc') - def classifier = 'javadoc' - if (GradleVersion.current() >= GradleVersion.version('5.1')) { - it.archiveClassifier.set(classifier) - } else { - it.classifier = classifier - } - it.from gradleProject.javadoc.destinationDir - } + JavaPluginExtension javaPluginExtension = gradleProject.extensions.getByType(JavaPluginExtension) + javaPluginExtension.withSourcesJar() + javaPluginExtension.withJavadocJar() if (!gradleProject.logger.isEnabled(INFO)) { gradleProject.tasks.withType(JavaCompile).configureEach { @@ -153,8 +132,9 @@ class JpiPlugin implements Plugin { configureRepositories(gradleProject) configureConfigurations(gradleProject) - configureManifest(gradleProject) configureJpi(gradleProject) + configureManifest(gradleProject) + configureLicenseInfo(gradleProject) configureTestDependencies(gradleProject) configurePublishing(gradleProject) configureTestHpl(gradleProject) @@ -175,13 +155,13 @@ class JpiPlugin implements Plugin { private static configureManifest(Project project) { JavaPluginConvention javaPluginConvention = project.convention.getPlugin(JavaPluginConvention) - TaskProvider warProvider = project.tasks.named(WarPlugin.WAR_TASK_NAME) as TaskProvider + TaskProvider jpiProvider = project.tasks.named(JPI_TASK_NAME) as TaskProvider TaskProvider jarProvider = project.tasks.named(JavaPlugin.JAR_TASK_NAME) as TaskProvider def configureManifest = project.tasks.register('configureManifest') { it.doLast { Map attributes = attributesToMap(new JpiManifest(project).mainAttributes) - warProvider.configure { + jpiProvider.configure { it.manifest.attributes(attributes) it.inputs.property('manifest', attributes) } @@ -194,7 +174,7 @@ class JpiPlugin implements Plugin { it.dependsOn(javaPluginConvention.sourceSets.getByName(MAIN_SOURCE_SET_NAME).output) } - warProvider.configure { it.dependsOn(configureManifest) } + jpiProvider.configure { it.dependsOn(configureManifest) } jarProvider.configure { it.dependsOn(configureManifest) } } @@ -202,28 +182,15 @@ class JpiPlugin implements Plugin { JpiExtension jpiExtension = project.extensions.getByType(JpiExtension) def jar = project.tasks.named(JavaPlugin.JAR_TASK_NAME) - def war = project.tasks.named(WarPlugin.WAR_TASK_NAME) - project.afterEvaluate { - war.configure { - it.description = 'Generates the JPI package' - def fileName = "${jpiExtension.shortName}.${jpiExtension.fileExtension}" - def extension = jpiExtension.fileExtension - if (GradleVersion.current() >= GradleVersion.version('5.1')) { - it.archiveFileName.set(fileName) - it.archiveExtension.set(extension) - } else { - it.archiveName = fileName - it.extension = extension - } - it.classpath -= project.sourceSets.main.output - it.classpath(jar) - } - } - - project.tasks.register(JPI_TASK_NAME) { - it.dependsOn(war) + project.tasks.register(JPI_TASK_NAME, War) { it.description = 'Generates the JPI package' it.group = BasePlugin.BUILD_GROUP + def fileName = "${jpiExtension.shortName}.${jpiExtension.fileExtension}" + def extension = jpiExtension.fileExtension + it.archiveFileName.set(fileName) + it.archiveExtension.set(extension) + it.classpath(jar, project.configurations.named(JavaPlugin.RUNTIME_CLASSPATH_CONFIGURATION_NAME)) + it.from(WEB_APP_DIR) } } @@ -280,16 +247,14 @@ class JpiPlugin implements Plugin { it.group = BasePlugin.BUILD_GROUP it.outputDirectory = new File(project.buildDir, 'licenses') it.configurations = [ - project.configurations[javaConvention.sourceSets.main.compileConfigurationName], - project.configurations[javaConvention.sourceSets.main.runtimeConfigurationName], + project.configurations[javaConvention.sourceSets.main.runtimeClasspathConfigurationName] ] it.providedConfigurations = [ - project.configurations[PROVIDED_COMPILE_CONFIGURATION_NAME], - project.configurations[PROVIDED_RUNTIME_CONFIGURATION_NAME], + project.configurations[COMPILE_ONLY_CONFIGURATION_NAME] ] } - project.tasks.named(WarPlugin.WAR_TASK_NAME).configure { + project.tasks.named(JPI_TASK_NAME).configure { it.webInf.from(licenseTask.get().outputDirectory) it.dependsOn(licenseTask) } @@ -354,9 +319,9 @@ class JpiPlugin implements Plugin { test.visible = false test.description = 'Jenkins plugin test dependencies.' - project.configurations.getByName(PROVIDED_COMPILE_CONFIGURATION_NAME).extendsFrom(core) - project.configurations.getByName(PROVIDED_COMPILE_CONFIGURATION_NAME).extendsFrom(plugins) - project.configurations.getByName(PROVIDED_COMPILE_CONFIGURATION_NAME).extendsFrom(optionalPlugins) + project.configurations.getByName(COMPILE_ONLY_CONFIGURATION_NAME).extendsFrom(core) + project.configurations.getByName(COMPILE_ONLY_CONFIGURATION_NAME).extendsFrom(plugins) + project.configurations.getByName(COMPILE_ONLY_CONFIGURATION_NAME).extendsFrom(optionalPlugins) project.configurations.getByName(TEST_IMPLEMENTATION_CONFIGURATION_NAME).extendsFrom(test) Configuration warDependencies = project.configurations.create(WAR_DEPENDENCY_CONFIGURATION_NAME) @@ -380,21 +345,12 @@ class JpiPlugin implements Plugin { // delay configuration until all settings are available (groupId, shortName, ...) project.afterEvaluate { if (jpiExtension.configurePublishing) { - Task jar = project.tasks.getByName(JavaPlugin.JAR_TASK_NAME) - Task sourcesJar = project.tasks.getByName(SOURCES_JAR_TASK_NAME) - Task javadocJar = project.tasks.getByName(JAVADOC_JAR_TASK_NAME) - project.plugins.apply(MavenPublishPlugin) PublishingExtension publishingExtension = project.extensions.getByType(PublishingExtension) publishingExtension.publications { mavenJpi(MavenPublication) { artifactId jpiExtension.shortName - - from(project.components.web) - - artifact jar - artifact sourcesJar - artifact javadocJar + from(project.components.java) new JpiPomCustomizer(project).customizePom(pom) } @@ -444,12 +400,12 @@ class JpiPlugin implements Plugin { resolvePluginDependencies( project, PLUGINS_DEPENDENCY_CONFIGURATION_NAME, - PROVIDED_COMPILE_CONFIGURATION_NAME + API_CONFIGURATION_NAME ) resolvePluginDependencies( project, OPTIONAL_PLUGINS_DEPENDENCY_CONFIGURATION_NAME, - PROVIDED_COMPILE_CONFIGURATION_NAME + API_CONFIGURATION_NAME ) resolvePluginDependencies( project, @@ -472,7 +428,7 @@ class JpiPlugin implements Plugin { } private static Dependency toDependency(Project project, ResolvedArtifact it, String from) { - project.dependencies.create("${it.moduleVersion.id}@jar") { Dependency d -> + project.dependencies.create("${it.moduleVersion.id}") { Dependency d -> d.because "JpiPlugin added jar for compilation support (plugin present on $from)" } } diff --git a/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPomCustomizer.groovy b/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPomCustomizer.groovy index d7580aa0..d31fc08d 100644 --- a/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPomCustomizer.groovy +++ b/src/main/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPomCustomizer.groovy @@ -3,12 +3,9 @@ package org.jenkinsci.gradle.plugins.jpi import groovy.transform.CompileStatic import org.gradle.api.Project import org.gradle.api.XmlProvider -import org.gradle.api.artifacts.Dependency import org.gradle.api.artifacts.DependencySet -import org.gradle.api.artifacts.ModuleDependency import org.gradle.api.artifacts.ModuleVersionIdentifier import org.gradle.api.artifacts.repositories.MavenArtifactRepository -import org.gradle.api.plugins.JavaPlugin import org.gradle.api.provider.Property import org.gradle.api.publish.maven.MavenPom import org.gradle.api.publish.maven.MavenPomDeveloper @@ -20,8 +17,6 @@ import org.gradle.api.publish.maven.MavenPomScm import static org.gradle.api.artifacts.ArtifactRepositoryContainer.DEFAULT_MAVEN_CENTRAL_REPO_NAME import static org.gradle.api.artifacts.ArtifactRepositoryContainer.DEFAULT_MAVEN_LOCAL_REPO_NAME import static org.jenkinsci.gradle.plugins.jpi.JpiPlugin.CORE_DEPENDENCY_CONFIGURATION_NAME -import static org.jenkinsci.gradle.plugins.jpi.JpiPlugin.OPTIONAL_PLUGINS_DEPENDENCY_CONFIGURATION_NAME -import static org.jenkinsci.gradle.plugins.jpi.JpiPlugin.PLUGINS_DEPENDENCY_CONFIGURATION_NAME /** * Adds metadata to the JPI's POM. @@ -103,67 +98,15 @@ class JpiPomCustomizer { if (repositories) { pom.appendNode('repositories', repositories.collect { makeRepositoryNode(it) }) } - fixDependencies(pom) + // TODO Can this be removed? 'provided' dependencies are not of for poms that are metadata (they are only for local project poms in Maven) + addProvidedDependencies(pom) } - private void fixDependencies(Node pom) { - DependencySet pluginDependencies = project.configurations. - getByName(PLUGINS_DEPENDENCY_CONFIGURATION_NAME).dependencies - DependencySet optionalPluginDependencies = project.configurations. - getByName(OPTIONAL_PLUGINS_DEPENDENCY_CONFIGURATION_NAME).dependencies + private void addProvidedDependencies(Node pom) { DependencySet coreDependencies = project.configurations. getByName(CORE_DEPENDENCY_CONFIGURATION_NAME).dependencies - DependencySet compileDependencies = project.configurations. - getByName(JavaPlugin.COMPILE_CONFIGURATION_NAME).dependencies - Set allPluginDependencies = pluginDependencies + optionalPluginDependencies - Node dependenciesNode = pom.dependencies[0] as Node dependenciesNode = dependenciesNode ?: pom.appendNode('dependencies') - (compileDependencies - coreDependencies + pluginDependencies + optionalPluginDependencies).each { - ModuleVersionIdentifier mvid = ResolvedDependencySelector.selectedModuleVersion( - project, - 'compile', - it.group, - it.name) - Node dependency = dependenciesNode.appendNode('dependency') - dependency.appendNode('groupId', it.group) - dependency.appendNode('artifactId', it.name) - dependency.appendNode('version', mvid.version ?: it.version) - } - dependenciesNode.each { Node dependency -> - String groupId = dependency.groupId.text() - String artifactId = dependency.artifactId.text() - Node scope = dependency.scope[0] as Node - Node exclusions = dependency.exclusions[0] as Node - - // add the optional element for all optional plugin dependencies - if (optionalPluginDependencies.any { it.group == groupId && it.name == artifactId }) { - dependency.appendNode('optional', true) - } - - // remove the scope for all plugin and compile dependencies - if (scope && (allPluginDependencies + compileDependencies).any { - it.group == groupId && it.name == artifactId - }) { - dependency.remove(scope) - } - - // remove exclusions from all plugin dependencies - if (exclusions && allPluginDependencies.any { it.group == groupId && it.name == artifactId }) { - dependency.remove(exclusions) - } - - compileDependencies.withType(ModuleDependency).find { - it.group == groupId && it.name == artifactId && it.excludeRules - }.each { - exclusions = dependency.appendNode('exclusions') - it.excludeRules.each { - Node exclusion = exclusions.appendNode('exclusion') - exclusion.appendNode('groupId', it.group) - exclusion.appendNode('artifactId', it.module) - } - } - } coreDependencies.each { Node dependency = dependenciesNode.appendNode('dependency') diff --git a/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiHplManifestSpec.groovy b/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiHplManifestSpec.groovy index a4a44a40..95f74d73 100644 --- a/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiHplManifestSpec.groovy +++ b/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiHplManifestSpec.groovy @@ -15,7 +15,6 @@ class JpiHplManifestSpec extends Specification { apply plugin: 'jpi' } def libraries = [ - new File(project.projectDir, 'src/main/resources'), new File(project.buildDir, 'classes/java/main'), new File(project.buildDir, 'resources/main'), ] diff --git a/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiIntegrationSpec.groovy b/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiIntegrationSpec.groovy index fdf59590..70e3e8f8 100644 --- a/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiIntegrationSpec.groovy +++ b/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiIntegrationSpec.groovy @@ -162,9 +162,8 @@ class JpiIntegrationSpec extends IntegrationSpec { where: task | dependency | outcome 'jar' | ':configureManifest' | TaskOutcome.SUCCESS - 'war' | ':configureManifest' | TaskOutcome.SUCCESS + 'jpi' | ':configureManifest' | TaskOutcome.SUCCESS 'processTestResources' | ':resolveTestDependencies' | TaskOutcome.NO_SOURCE - 'jpi' | ':war' | TaskOutcome.SUCCESS 'compileTestJava' | ':insertTest' | TaskOutcome.SKIPPED 'testClasses' | ':generate-test-hpl' | TaskOutcome.SUCCESS 'compileJava' | ':localizer' | TaskOutcome.SUCCESS diff --git a/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPluginSpec.groovy b/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPluginSpec.groovy index 60007ca9..79dce67d 100644 --- a/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPluginSpec.groovy +++ b/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPluginSpec.groovy @@ -90,11 +90,6 @@ class JpiPluginSpec extends Specification { (project as ProjectInternal).evaluate() then: - Task warTask = project.tasks[WarPlugin.WAR_TASK_NAME] - warTask != null - warTask.description != null - warTask.group == BasePlugin.BUILD_GROUP - Task jpiTask = project.tasks[JpiPlugin.JPI_TASK_NAME] jpiTask != null jpiTask.description != null diff --git a/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPomCustomizerIntegrationSpec.groovy b/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPomCustomizerIntegrationSpec.groovy index fa4c151c..9251147a 100644 --- a/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPomCustomizerIntegrationSpec.groovy +++ b/src/test/groovy/org/jenkinsci/gradle/plugins/jpi/JpiPomCustomizerIntegrationSpec.groovy @@ -227,8 +227,13 @@ class JpiPomCustomizerIntegrationSpec extends IntegrationSpec { jenkinsPlugin { coreVersion = '1.580.1' } + java { + registerFeature('credentials') { + usingSourceSet(sourceSets.main) + } + } dependencies { - optionalJenkinsPlugins 'org.jenkins-ci.plugins:credentials:1.9.4' + credentialsImplementation 'org.jenkins-ci.plugins:credentials:1.9.4' } """.stripIndent() @@ -328,7 +333,7 @@ class JpiPomCustomizerIntegrationSpec extends IntegrationSpec { void generatePom() { gradleRunner() - .withArguments('generatePomFileForMavenJpiPublication') + .withArguments('generatePomFileForMavenJpiPublication', '-s') .build() } diff --git a/src/test/resources/org/jenkinsci/gradle/plugins/jpi/compile-dependencies-pom.xml b/src/test/resources/org/jenkinsci/gradle/plugins/jpi/compile-dependencies-pom.xml index 2a75aa33..dfaac50d 100644 --- a/src/test/resources/org/jenkinsci/gradle/plugins/jpi/compile-dependencies-pom.xml +++ b/src/test/resources/org/jenkinsci/gradle/plugins/jpi/compile-dependencies-pom.xml @@ -8,17 +8,12 @@ unspecified hpi test - - - jenkins - https://repo.jenkins-ci.org/public/ - - javax.ejb ejb 2.1 + compile org.jenkins-ci.main @@ -39,4 +34,10 @@ provided + + + jenkins + https://repo.jenkins-ci.org/public/ + + diff --git a/src/test/resources/org/jenkinsci/gradle/plugins/jpi/compile-dependencies-with-excludes-pom.xml b/src/test/resources/org/jenkinsci/gradle/plugins/jpi/compile-dependencies-with-excludes-pom.xml index 8fb143d1..22c9cb78 100644 --- a/src/test/resources/org/jenkinsci/gradle/plugins/jpi/compile-dependencies-with-excludes-pom.xml +++ b/src/test/resources/org/jenkinsci/gradle/plugins/jpi/compile-dependencies-with-excludes-pom.xml @@ -8,21 +8,16 @@ unspecified hpi test - - - jenkins - https://repo.jenkins-ci.org/public/ - - org.bitbucket.b_c jose4j 0.5.5 + compile - org.slf4j slf4j-api + org.slf4j @@ -45,4 +40,10 @@ provided + + + jenkins + https://repo.jenkins-ci.org/public/ + + diff --git a/src/test/resources/org/jenkinsci/gradle/plugins/jpi/optional-plugin-dependencies-pom.xml b/src/test/resources/org/jenkinsci/gradle/plugins/jpi/optional-plugin-dependencies-pom.xml index bdfed3fe..a85c0ba1 100644 --- a/src/test/resources/org/jenkinsci/gradle/plugins/jpi/optional-plugin-dependencies-pom.xml +++ b/src/test/resources/org/jenkinsci/gradle/plugins/jpi/optional-plugin-dependencies-pom.xml @@ -8,17 +8,12 @@ unspecified hpi test - - - jenkins - https://repo.jenkins-ci.org/public/ - - org.jenkins-ci.plugins credentials 1.9.4 + compile true @@ -40,4 +35,10 @@ provided + + + jenkins + https://repo.jenkins-ci.org/public/ + + diff --git a/src/test/resources/org/jenkinsci/gradle/plugins/jpi/plugin-dependencies-pom.xml b/src/test/resources/org/jenkinsci/gradle/plugins/jpi/plugin-dependencies-pom.xml index 36ed2e3d..8802aecc 100644 --- a/src/test/resources/org/jenkinsci/gradle/plugins/jpi/plugin-dependencies-pom.xml +++ b/src/test/resources/org/jenkinsci/gradle/plugins/jpi/plugin-dependencies-pom.xml @@ -8,17 +8,12 @@ unspecified hpi test - - - jenkins - https://repo.jenkins-ci.org/public/ - - org.jenkins-ci.plugins credentials 1.9.4 + compile org.jenkins-ci.main @@ -39,4 +34,10 @@ provided + + + jenkins + https://repo.jenkins-ci.org/public/ + +