blob: 4f6c7816dfa06b9c55c5acf43bd9fae0cf8ba172 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright 2005 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.
-->
<!-- $Rev$ $Date$ -->
<project
xmlns:j="jelly:core"
xmlns:artifact="artifact"
xmlns:ant="jelly:ant"
xmlns:velocity="jelly:velocity"
xmlns:define="jelly:define"
xmlns:car="geronimo:packaging"
>
<define:taglib uri="geronimo:packaging">
<define:jellybean name="package" className="org.apache.geronimo.plugin.packaging.PackageBuilderShell" method="execute"/>
<define:jellybean name="dependencies" className="org.apache.geronimo.plugin.packaging.PlanProcessor" method="execute"/>
<define:jellybean name="copyConfigs" className="org.apache.geronimo.plugin.packaging.ConfigCopier" method="execute"/>
</define:taglib>
<goal name="car" description="Package a Geronimo Configuration" prereqs="car:package"/>
<goal name="car:prepare-plan" description="Add dependencies to a plan and process with velocity">
<car:dependencies
groupId="${pom.groupId}"
artifactId="${pom.artifactId}"
version="${pom.currentVersion}"
artifacts="${pom.artifacts}"
targetDir="${geronimo.packaging.buildDir}"
sourceDir="${geronimo.packaging.srcDir}"
planFile="${geronimo.packaging.planFile}"
targetFile="${geronimo.packaging.buildFile}"
context="${context}"/>
</goal>
<goal name="car:package" prereqs="car:prepare-plan" description="Package a Geronimo Configuration">
<delete dir="${geronimo.packaging.targetRepository}"/>
<mkdir dir="${geronimo.packaging.targetRepository}"/>
<car:package
context="${context}"
artifacts="${pom.artifacts}"
pluginArtifacts="${plugin.artifacts}"
repository="${geronimo.packaging.repository}"
targetRepository="${geronimo.packaging.targetRepository}"
deployerName="${geronimo.packaging.deployerName}"
planFile="${geronimo.packaging.buildFile}"
moduleFile="${geronimo.packaging.moduleFile}"
packageFile="${maven.build.dir}/${maven.final.name}.car"
mainClass="${geronimo.packaging.mainClass}"
mainGBean="${geronimo.packaging.mainGBean}"
mainMethod="${geronimo.packaging.mainMethod}"
configurations="${geronimo.packaging.configurations}"
classPath="${geronimo.packaging.classPath}"
endorsedDirs="${geronimo.packaging.endorsedDirs}"
extensionDirs="${geronimo.packaging.extensionDirs}"
explicitResolutionLocation="${geronimo.packaging.explicit.versions}"
logLevel="${geronimo.packaging.logLevel}"
/>
</goal>
<goal name="car:install" prereqs="car:package" description="Install the package in the local repository">
<j:catch>
<artifact:install artifact="${maven.build.dir}/${maven.final.name}.car" type="car" project="${pom}"/>
</j:catch>
<j:catch>
<echo>about to copy configs</echo>
<car:copyConfigs
sourceRepositoryClass="${geronimo.packaging.install.sourceRepositoryClass}"
sourceConfigurationStoreClass="${geronimo.packaging.install.sourceConfigurationStoreClass}"
sourceRepositoryLocation="${geronimo.packaging.install.sourceRepositoryLocation}"
targetRepositoryClass="${geronimo.packaging.install.targetRepositoryClass}"
targetConfigurationStoreClass="${geronimo.packaging.install.targetConfigurationStoreClass}"
targetRepositoryLocation="${geronimo.packaging.install.targetRepositoryLocation}"
/>
<echo>done copying configs</echo>
</j:catch>
</goal>
</project>