From 0c3b2e5215a6e94f385a7f3472ae7719da4ac410 Mon Sep 17 00:00:00 2001 From: Benjamin Bentmann Date: Fri, 28 Nov 2008 22:48:39 +0000 Subject: [PATCH] o Deleted unused IT plugin (superseded by maven-it-plugin-configuration) git-svn-id: https://svn.apache.org/repos/asf/maven/core-integration-testing/trunk@721582 13f79535-47bb-0310-9956-ffa450edef68 --- .../src/test/resources/bootstrap/pom.xml | 6 - .../pom.xml | 48 -------- .../InterpolatedPomConfigurationMojo.java | 111 ------------------ its/core-it-support/core-it-plugins/pom.xml | 1 - 4 files changed, 166 deletions(-) delete mode 100644 its/core-it-support/core-it-plugins/maven-it-plugin-generate-properties/pom.xml delete mode 100644 its/core-it-support/core-it-plugins/maven-it-plugin-generate-properties/src/main/java/org/apache/maven/plugin/coreit/InterpolatedPomConfigurationMojo.java diff --git a/its/core-it-suite/src/test/resources/bootstrap/pom.xml b/its/core-it-suite/src/test/resources/bootstrap/pom.xml index 1cacb1e469..6d49c767b9 100644 --- a/its/core-it-suite/src/test/resources/bootstrap/pom.xml +++ b/its/core-it-suite/src/test/resources/bootstrap/pom.xml @@ -119,12 +119,6 @@ under the License. ${itPluginVersion} runtime - - org.apache.maven.its.plugins - maven-it-plugin-generate-properties - ${itPluginVersion} - runtime - org.apache.maven.its.plugins maven-it-plugin-no-project diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-generate-properties/pom.xml b/its/core-it-support/core-it-plugins/maven-it-plugin-generate-properties/pom.xml deleted file mode 100644 index 983f373736..0000000000 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-generate-properties/pom.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - 4.0.0 - - - maven-it-plugins - org.apache.maven.its.plugins - 2.1-SNAPSHOT - - - maven-it-plugin-generate-properties - maven-plugin - - Maven Integration Test Plugin :: Interpolated POM Configuration - 2006 - - - true - - - - - org.apache.maven - maven-plugin-api - 2.0 - - - diff --git a/its/core-it-support/core-it-plugins/maven-it-plugin-generate-properties/src/main/java/org/apache/maven/plugin/coreit/InterpolatedPomConfigurationMojo.java b/its/core-it-support/core-it-plugins/maven-it-plugin-generate-properties/src/main/java/org/apache/maven/plugin/coreit/InterpolatedPomConfigurationMojo.java deleted file mode 100644 index bd7e134de2..0000000000 --- a/its/core-it-support/core-it-plugins/maven-it-plugin-generate-properties/src/main/java/org/apache/maven/plugin/coreit/InterpolatedPomConfigurationMojo.java +++ /dev/null @@ -1,111 +0,0 @@ -package org.apache.maven.plugin.coreit; - -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ - -import org.apache.maven.plugin.AbstractMojo; -import org.apache.maven.plugin.MojoExecutionException; - -import java.util.Properties; -import java.io.FileOutputStream; -import java.io.File; - -/** - * Take some configuration values that use interpolated POM values and write them to a properties file - * to make sure they are passing through the system properly. We are using this mojo in it0088, and the - * configuration looks like the following: - * - * - * org.apache.maven.its.plugins - * maven-it-plugin-generate-properties - * 1.0-SNAPSHOT - * - * - * process-resources - * - * ${project.build.directory} - * target - * target - * - * - * generate-properties - * - * - * - * - * - * @goal generate-properties - * - */ -public class InterpolatedPomConfigurationMojo - extends AbstractMojo -{ - /** - * @parameter expression="${basedir}" - */ - private String basedir; - - /** - * This is using the plugin configuration above and so ${project.build.directory} is the value - * of the expression ${projectBuildDirectory} and should be the full path to the scratch directory - * which often looks something like /path/to/project/target. For the 2.0.x family this always results - * in a full path, and bugs have resulted when it resolves to something that is not a full path like "target". - * - * @parameter expression="${projectBuildDirectory}" - */ - private String projectBuildDirectory; - - /** - * @parameter expression="${targetDirectoryString}" - */ - private String targetDirectoryString; - - /** - * @parameter expression="${targetDirectoryFile}" - */ - private File targetDirectoryFile; - - public void execute() - throws MojoExecutionException - { - try - { - Properties mojoGeneratedPropeties = new Properties(); - - mojoGeneratedPropeties.put( "project.build.directory", projectBuildDirectory ); - - if ( targetDirectoryString != null ) - { - mojoGeneratedPropeties.put( "targetDirectoryString", targetDirectoryString ); - } - if ( targetDirectoryFile != null ) - { - mojoGeneratedPropeties.put( "targetDirectoryFile", targetDirectoryFile.getAbsolutePath() ); - } - - FileOutputStream fos = new FileOutputStream( new File( basedir, "target/mojo-generated.properties" ) ); - - mojoGeneratedPropeties.store( fos, "# Properties generated by the execution of a mojo that uses interpolated POM values for configuration." ); - } - catch( Exception e ) - { - getLog().error( "Error creating mojo generated properties.", e ); - } - } -} diff --git a/its/core-it-support/core-it-plugins/pom.xml b/its/core-it-support/core-it-plugins/pom.xml index 6b2b795589..2201abf282 100644 --- a/its/core-it-support/core-it-plugins/pom.xml +++ b/its/core-it-support/core-it-plugins/pom.xml @@ -44,7 +44,6 @@ under the License. maven-it-plugin-expression maven-it-plugin-file maven-it-plugin-fork - maven-it-plugin-generate-properties maven-it-plugin-no-project maven-it-plugin-packaging maven-it-plugin-parameter-implementation