Initial revision

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@163393 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Brett Leslie Porter 2005-02-24 02:50:16 +00:00
parent 6bafc23fc4
commit 34c16816ec
6 changed files with 98 additions and 0 deletions

View File

@ -0,0 +1,10 @@
*~
*.log
target
*.ipr
*.iws
dist
target
.classpath
.project
log.txt

View File

@ -0,0 +1,2 @@
target/maven-it0013-plugin-1.0-SNAPSHOT.jar
target/it0013-verify

View File

@ -0,0 +1,3 @@
plugin:descriptor
install
it0013:it0013

View File

@ -0,0 +1,18 @@
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>maven</groupId>
<artifactId>maven-core-it0013</artifactId>
<version>3.8.1</version>
<dependencies>
<dependency>
<groupId>maven</groupId>
<artifactId>maven-plugin</artifactId>
<version>2.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${version}</version>
</dependency>
</dependencies>
</project>

View File

@ -0,0 +1 @@
rm ${localRepository}/maven/plugins/maven-core-it-plugin-1.0-SNAPSHOT.jar

View File

@ -0,0 +1,64 @@
package org.apache.maven.plugin.coreit;
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* Licensed 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.AbstractPlugin;
import org.apache.maven.plugin.PluginExecutionRequest;
import org.apache.maven.plugin.PluginExecutionResponse;
import java.io.File;
import java.io.FileWriter;
/**
* @goal it0013
*
* @description touches a test file
*
* @parameter
* name="outputDirectory"
* type="String"
* required="true"
* validator=""
* expression="#project.build.directory"
* description=""
*/
public class CoreItMojo
extends AbstractPlugin
{
private static final int DELETE_RETRY_SLEEP_MILLIS = 10;
public void execute( PluginExecutionRequest request, PluginExecutionResponse response )
throws Exception
{
String outputDirectory = (String) request.getParameter( "outputDirectory" );
File f = new File( outputDirectory );
if ( !f.exists() )
{
f.mkdirs();
}
File touch = new File( f, "it0013-verify" );
FileWriter w = new FileWriter( touch );
w.write( "it0013-verify" );
w.close();
}
}