git-svn-id: https://svn.apache.org/repos/asf/maven/maven-1/plugins/trunk@114791 13f79535-47bb-0310-9956-ffa450edef68
69 lines
2.2 KiB
XML
69 lines
2.2 KiB
XML
<!--
|
|
/*
|
|
* 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.
|
|
*/
|
|
-->
|
|
<project default="plugin">
|
|
|
|
<goal name="plugin">
|
|
<!-- set up the directory the jar will be assembled to -->
|
|
<property name="assemblyDir" value="target/assemblyDir"/>
|
|
|
|
<mkdir dir="${assemblyDir}"/>
|
|
|
|
<!-- copy the plugin files to the assembly directory -->
|
|
<copy todir="${assemblyDir}">
|
|
<fileset dir=".">
|
|
<exclude name="**/target/**"/>
|
|
<exclude name="src/**"/>
|
|
<exclude name="maven.xml"/>
|
|
<exclude name="maven.log"/>
|
|
<exclude name="**/velocity.log"/>
|
|
<exclude name="**/.cvsignore"/>
|
|
</fileset>
|
|
</copy>
|
|
|
|
<!-- jar the files up -->
|
|
<jar jarfile="${maven.build.dir}/${maven.final.name}.jar">
|
|
<fileset dir="${assemblyDir}"/>
|
|
</jar>
|
|
|
|
<!-- copy the jar to the local repository as a maven jar -->
|
|
<copy
|
|
file="${maven.build.dir}/${maven.final.name}.jar"
|
|
todir="${maven.repo.local}/maven/jars"/>
|
|
</goal>
|
|
|
|
<!-- install the plugin in the maven home directory -->
|
|
<goal name="plugin:install" prereqs="plugin"
|
|
description="Install the plugin in Maven's plugins dir">
|
|
|
|
<copy file="${maven.build.dir}/${maven.final.name}.jar"
|
|
todir="${maven.home}/plugins"/>
|
|
|
|
</goal>
|
|
|
|
<!-- unzip the jar file into a plugin directory -->
|
|
<goal name="plugin:deploy" prereqs="plugin"
|
|
description="Install an unpacked version of the plugin">
|
|
|
|
<mkdir dir="${maven.home}/plugins/${maven.final.name}"/>
|
|
<unzip src="${maven.build.dir}/${maven.final.name}.jar"
|
|
dest="${maven.home}/plugins/${maven.final.name}"/>
|
|
|
|
</goal>
|
|
|
|
</project>
|
|
|