You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by di...@apache.org on 2003/02/10 04:55:22 UTC

cvs commit: jakarta-turbine-maven/src/plugins-build/ejb plugin.jelly

dion        2003/02/09 19:55:22

  Modified:    src/plugins-build/ejb plugin.jelly
  Log:
  Use license file from license plugin rather than hardcoding
  
  Revision  Changes    Path
  1.2       +101 -98   jakarta-turbine-maven/src/plugins-build/ejb/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins-build/ejb/plugin.jelly,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- plugin.jelly	24 Jan 2003 03:45:10 -0000	1.1
  +++ plugin.jelly	10 Feb 2003 03:55:22 -0000	1.2
  @@ -1,98 +1,101 @@
  -<?xml version="1.0"?>
  -
  -<project xmlns:j="jelly:core">
  -
  -  <!--==================================================================-->
  -  <!-- Default goal : Builds a ejb file                                 -->
  -  <!--==================================================================-->
  -  <goal name="ejb" prereqs="ejb:ejb" description="Build an ejb file"/>
  -
  -  <!--==================================================================-->
  -  <!-- Initializations                                                  -->
  -  <!--==================================================================-->
  -  <goal name="ejb:init" 
  -    description="Initialize filesystem and other resources for an ejb build">
  -
  -
  -    <j:if test="${sourcesPresent == 'true'}">
  -      <attainGoal name="java:compile"/>
  -      <attainGoal name="test:test"/>
  -    </j:if>
  -
  -  </goal>
  -  
  -  <!--==================================================================-->
  -  <!-- Builds an ejb file                                               -->
  -  <!--==================================================================-->
  -  <goal name="ejb:ejb" prereqs="ejb:init" description="Build an ejb file">
  -
  -    <echo>Building ejb ${maven.final.name}</echo>
  -
  -    <available property="maven.ejb.manifest.available"
  -      file="${maven.ejb.manifest}"/>
  -
  -    <j:forEach var="dep" items="${pom.dependencies}">
  -      <j:if test="${dep.getProperty('ejb.manifest.classpath')=='true'}">
  -        <j:set var="maven.ejb.classpath" value="${maven.ejb.classpath} ${dep.artifact}"/>
  -      </j:if>
  -    </j:forEach>
  -
  -    <!-- jar task used for now due to problems with ejb jar not including 
  -         files other than class files -->
  -    <jar jarfile="${maven.build.dir}/${maven.final.name}.jar">
  -      
  -      <!-- include marked dependencies -->
  -      <j:forEach var="dep" items="${pom.dependencies}">
  -        <j:if test="${dep.getProperty('ejb.bundle.jar')=='true'}">
  -          <fileset dir="${maven.repo.local}/${dep.artifactDirectory}/jars/">
  -            <include name="${dep.artifact}"/>
  -          </fileset>
  -        </j:if>
  -      </j:forEach>
  - 
  -
  -      <j:if test="${maven.ejb.manifest.available}">
  -        <setProperty name="manifest" value="${maven.ejb.manifest}" />
  -      </j:if>
  -
  -      <metainf dir="${basedir}">
  -        <include name="LICENSE.txt"/>
  -      </metainf>
  -      <manifest>
  -        <attribute name="Built-By" value="${user.name}"/>
  -        <attribute name="Created-By" value="Apache Jakarta Maven"/>
  -        <attribute name="Package" value="${pom.package}"/>
  -        <attribute name="Class-Path" value="${maven.ejb.classpath}"/>
  -        <section name="${pom.package}">
  -          <attribute name="Specification-Title" value="${pom.artifactId}"/>
  -          <attribute name="Specification-Version" value="${pom.currentVersion}"/>
  -          <attribute name="Specification-Vendor" value="${pom.organization.name}"/>
  -          <attribute name="Implementation-Title" value="${pom.package}"/>
  -          <attribute name="Implementation-Version" value="${pom.currentVersion}"/>
  -          <attribute name="Implementation-Vendor" value="${pom.organization.name}"/>
  -        </section>
  -      </manifest>
  -    
  -      <fileset dir="${maven.ejb.src}"/>
  -      <fileset dir="${maven.build.dest}"/>
  -
  -    </jar>
  -
  -  </goal>
  -
  -  <!--==================================================================-->
  -  <!-- Install the ejb in the local repository                          -->
  -  <!--==================================================================-->
  -  <goal name="ejb:install"
  -        prereqs="ejb:ejb"
  -        description="Install the ejb in the local repository">
  -
  -    <property name="maven.ejb.install.dir"
  -      value="${maven.repo.local}/${pom.artifactDirectory}/ejbs"/>
  -    <mkdir dir="${maven.ejb.install.dir}"/>
  -    <copy file="${maven.build.dir}/${maven.final.name}.jar"
  -      tofile="${maven.ejb.install.dir}/${maven.final.name}.jar"/>
  -
  -  </goal>
  -
  -</project>
  +<?xml version="1.0"?>
  +
  +<project xmlns:j="jelly:core">
  +
  +  <!--==================================================================-->
  +  <!-- Default goal : Builds a ejb file                                 -->
  +  <!--==================================================================-->
  +  <goal name="ejb" prereqs="ejb:ejb" description="Build an ejb file"/>
  +
  +  <!--==================================================================-->
  +  <!-- Initializations                                                  -->
  +  <!--==================================================================-->
  +  <goal name="ejb:init" 
  +    description="Initialize filesystem and other resources for an ejb build">
  +
  +
  +    <j:if test="${sourcesPresent == 'true'}">
  +      <attainGoal name="java:compile"/>
  +      <attainGoal name="test:test"/>
  +    </j:if>
  +
  +  </goal>
  +  
  +  <!--==================================================================-->
  +  <!-- Builds an ejb file                                               -->
  +  <!--==================================================================-->
  +  <goal name="ejb:ejb" prereqs="ejb:init" description="Build an ejb file">
  +
  +    <echo>Building ejb ${maven.final.name}</echo>
  +
  +    <available property="maven.ejb.manifest.available"
  +      file="${maven.ejb.manifest}"/>
  +
  +    <j:forEach var="dep" items="${pom.dependencies}">
  +      <j:if test="${dep.getProperty('ejb.manifest.classpath')=='true'}">
  +        <j:set var="maven.ejb.classpath" value="${maven.ejb.classpath} ${dep.artifact}"/>
  +      </j:if>
  +    </j:forEach>
  +
  +    <!-- jar task used for now due to problems with ejb jar not including 
  +         files other than class files -->
  +    <jar jarfile="${maven.build.dir}/${maven.final.name}.jar">
  +      
  +      <!-- include marked dependencies -->
  +      <j:forEach var="dep" items="${pom.dependencies}">
  +        <j:if test="${dep.getProperty('ejb.bundle.jar')=='true'}">
  +          <fileset dir="${maven.repo.local}/${dep.artifactDirectory}/jars/">
  +            <include name="${dep.artifact}"/>
  +          </fileset>
  +        </j:if>
  +      </j:forEach>
  + 
  +
  +      <j:if test="${maven.ejb.manifest.available}">
  +        <setProperty name="manifest" value="${maven.ejb.manifest}" />
  +      </j:if>
  +
  +      <j:set var="licenseFileName"><license:fileName/></j:set>
  +      <util:file name="${licenseFileName}" var="licenseFile"/>
  +      <metainf dir="${licenseFile.canonicalFile.parent}">
  +        <include name="${licenseFile.canonicalFile.name}"/>
  +      </metainf>
  +
  +      <manifest>
  +        <attribute name="Built-By" value="${user.name}"/>
  +        <attribute name="Created-By" value="Apache Jakarta Maven"/>
  +        <attribute name="Package" value="${pom.package}"/>
  +        <attribute name="Class-Path" value="${maven.ejb.classpath}"/>
  +        <section name="${pom.package}">
  +          <attribute name="Specification-Title" value="${pom.artifactId}"/>
  +          <attribute name="Specification-Version" value="${pom.currentVersion}"/>
  +          <attribute name="Specification-Vendor" value="${pom.organization.name}"/>
  +          <attribute name="Implementation-Title" value="${pom.package}"/>
  +          <attribute name="Implementation-Version" value="${pom.currentVersion}"/>
  +          <attribute name="Implementation-Vendor" value="${pom.organization.name}"/>
  +        </section>
  +      </manifest>
  +    
  +      <fileset dir="${maven.ejb.src}"/>
  +      <fileset dir="${maven.build.dest}"/>
  +
  +    </jar>
  +
  +  </goal>
  +
  +  <!--==================================================================-->
  +  <!-- Install the ejb in the local repository                          -->
  +  <!--==================================================================-->
  +  <goal name="ejb:install"
  +        prereqs="ejb:ejb"
  +        description="Install the ejb in the local repository">
  +
  +    <property name="maven.ejb.install.dir"
  +      value="${maven.repo.local}/${pom.artifactDirectory}/ejbs"/>
  +    <mkdir dir="${maven.ejb.install.dir}"/>
  +    <copy file="${maven.build.dir}/${maven.final.name}.jar"
  +      tofile="${maven.ejb.install.dir}/${maven.final.name}.jar"/>
  +
  +  </goal>
  +
  +</project>