alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

What this is

This file is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Other links

The source code

<?xml version="1.0" encoding="UTF-8"?>

<!-- build script to create a plugin from ${plugin} -->
<project name="${plugin}" default="export plug-in [_3.4.0]" basedir="..">

<target name="export plug-in [_3.4.0]">
    <tstamp/>
	<antcall target="zz_internal_export">
		<param name="test_performance_version" value="3.4.0"/>
	</antcall>
</target>
<target name="export plug-in [_3.4.0.qualifier] (binary only)">
    <tstamp/>
	<property name="qualifier" value="${DSTAMP}${TSTAMP}" />
	<antcall target="zz_internal_export_binary_only">
		<param name="test_performance_version" value="3.4.0.${qualifier}"/>
	</antcall>
</target>
<target name="export plug-in [_3.4.0.qualifier] (with sources)">
    <tstamp/>
	<property name="qualifier" value="${DSTAMP}${TSTAMP}" />
	<antcall target="zz_internal_export">
		<param name="test_performance_version" value="3.4.0.${qualifier}"/>
	</antcall>
</target>

<target name="zz_internal_export">

	<tstamp/>
	<property name="export-dir" value="./org.eclipse.releng.basebuilder/plugins" />
	<property name="plugin" value="org.eclipse.test.performance" />
	<property name="plugin-dir" value="${export-dir}/${plugin}_${test_performance_version}"/>

	<echo message="TARGET: ${export-dir}" />
	<mkdir dir="${export-dir}" />

	<echo message="UPDATE ${plugin}_${test_performance_version}.jar" />
	<copy todir="${plugin}/META-INF">
		<fileset dir="META-INF" />
	</copy>  
	<replaceregexp file="${export-dir}/META-INF/MANIFEST.MF" match="Bundle-Version: ((\d)+\.(\d)+\.(\d)+\.)qualifier" replace="Bundle-Version: \1${qualifier}" byline="true" />
	<zip zipfile="${export-dir}/${plugin}_${test_performance_version}.jar">
		<fileset dir=".">
		  <include name="plugin.xml" />
		  <include name="plugin.properties" />
          <include name="about.html"/>
        </fileset>
		<fileset dir="${export-dir}">
			<include name="META-INF/**" />
		</fileset>
        <fileset dir="bin" />
        <zipfileset dir="src" prefix="src"/>
	</zip>
	<delete dir="${export-dir}/META-INF" />

</target>

<target name="zz_internal_export_binary_only">

	<tstamp/>
	<property name="export-dir" value="../org.eclipse.releng.basebuilder/plugins" />
	<property name="plugin" value="org.eclipse.test.performance" />
	<property name="plugin-dir" value="${export-dir}/${plugin}_${test_performance_version}"/>

	<echo message="TARGET: ${export-dir}" />
	<mkdir dir="${export-dir}" />

	<echo message="UPDATE ${plugin}_${test_performance_version}.jar" />
	<copy todir="${export-dir}/META-INF">
		<fileset dir="META-INF" />
	</copy>  
	<replaceregexp file="${export-dir}/META-INF/MANIFEST.MF" match="Bundle-Version: ((\d)+\.(\d)+\.(\d)+\.)qualifier" replace="Bundle-Version: \1${qualifier}" byline="true" />
	<zip zipfile="${export-dir}/${plugin}_${test_performance_version}.jar">
		<fileset dir=".">
		  <include name="plugin.xml" />
		  <include name="plugin.properties" />
	      <include name=".options"/>
          <include name="about.html"/>
        </fileset>
		<fileset dir="${export-dir}">
			<include name="META-INF/**" />
		</fileset>
        <fileset dir="bin" />
	</zip>
	<delete dir="${export-dir}/META-INF" />

</target>

</project>
... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2024 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.