notify-dpml AT lists.ibiblio.org
Subject: DPML Notify
List archive
svn commit: r1630 - in development/main: . magic magic/core/src/main/net/dpml/magic/builder magic/core/src/main/net/dpml/magic/model magic/core/src/main/net/dpml/magic/project magic/core/src/main/net/dpml/magic/tasks transit transit/handler transit/plugin transit/plugin/etc/bin util
- From: mcconnell AT netcompartner.com
- To: notify-dpml AT lists.ibiblio.org
- Subject: svn commit: r1630 - in development/main: . magic magic/core/src/main/net/dpml/magic/builder magic/core/src/main/net/dpml/magic/model magic/core/src/main/net/dpml/magic/project magic/core/src/main/net/dpml/magic/tasks transit transit/handler transit/plugin transit/plugin/etc/bin util
- Date: Sun, 30 Jan 2005 07:47:40 +0100
Author: mcconnell
Date: Sun Jan 30 07:47:37 2005
New Revision: 1630
Removed:
development/main/transit/dist.xml
Modified:
development/main/index.xml
development/main/magic/core/src/main/net/dpml/magic/builder/XMLDefinitionBuilder.java
development/main/magic/core/src/main/net/dpml/magic/model/Info.java
development/main/magic/core/src/main/net/dpml/magic/model/Resource.java
development/main/magic/core/src/main/net/dpml/magic/project/ProjectPath.java
development/main/magic/core/src/main/net/dpml/magic/tasks/ReactorTask.java
development/main/magic/index.xml
development/main/transit/handler/build.xml
development/main/transit/index.xml
development/main/transit/module.xml
development/main/transit/plugin/build.xml
development/main/transit/plugin/etc/bin/transit.bat
development/main/util/index.xml
development/main/util/module.xml
Log:
Update Magic to support multiple types per project/resource and sync. the
rest of the build process against this. This commit enabled an automated
build a complete Transit application bundle. Still more updates needed on
unix scripts. Please note - this update removes the automatic updating of
the installed dpml home content. I.e. to update a local installation will
requiore unpacking of a distribution (people are going to hate this). ALso
removed all magic index dependencies from the util and transit modules and
moved the application bundle creation logic into the transit module.xml file
imder the 'dist' target.
Modified: development/main/index.xml
==============================================================================
--- development/main/index.xml (original)
+++ development/main/index.xml Sun Jan 30 07:47:37 2005
@@ -23,9 +23,11 @@
<import index="util/index.xml"/>
<import index="transit/index.xml"/>
+ <!--
<import index="magic/index.xml"/>
<import index="metro/index.xml"/>
<import index="central/index.xml"/>
<import index="planet/facilities/index.xml"/>
+ -->
</index>
Modified:
development/main/magic/core/src/main/net/dpml/magic/builder/XMLDefinitionBuilder.java
==============================================================================
---
development/main/magic/core/src/main/net/dpml/magic/builder/XMLDefinitionBuilder.java
(original)
+++
development/main/magic/core/src/main/net/dpml/magic/builder/XMLDefinitionBuilder.java
Sun Jan 30 07:47:37 2005
@@ -175,19 +175,53 @@
public static Info createInfo( Index home, final Element info, boolean
external )
{
final String group =
- ElementHelper.getValue(
- ElementHelper.getChild( info, "group" ) );
+ ElementHelper.getValue( ElementHelper.getChild( info, "group" ) );
final String name =
- ElementHelper.getValue(
- ElementHelper.getChild( info, "name" ) );
- final String type =
- ElementHelper.getValue(
- ElementHelper.getChild( info, "type" ) );
+ ElementHelper.getValue( ElementHelper.getChild( info, "name" ) );
- final String version = createVersion( home, info, external );
+ final String[] types = createTypes( info, name );
+ final String version = createVersion( home, info, external );
final boolean status = createSnapshotPolicy( home, info, external );
- return Info.create( group, name, version, type, status );
+ return Info.create( group, name, version, types, status );
+ }
+
+ private static String[] createTypes( Element info, String name )
+ {
+ Element types = ElementHelper.getChild( info, "types" );
+ if( null != types )
+ {
+ Element[] children = ElementHelper.getChildren( types, "type" );
+ if( children.length == 0 )
+ {
+ return new String[]{ "jar" };
+ }
+ else
+ {
+ String[] values = new String[ children.length ];
+ for( int i=0; i<children.length; i++ )
+ {
+ Element child = children[i];
+ String type = ElementHelper.getValue( child );
+ values[i] = type;
+ }
+ return values;
+ }
+ }
+ else
+ {
+ Element typeElement = ElementHelper.getChild( info, "type" );
+ if( null != typeElement )
+ {
+ final String type =
+ ElementHelper.getValue( typeElement );
+ return new String[]{ type };
+ }
+ else
+ {
+ return new String[]{ "jar" };
+ }
+ }
}
private static String createVersion( Index home, Element info, boolean
external )
Modified: development/main/magic/core/src/main/net/dpml/magic/model/Info.java
==============================================================================
--- development/main/magic/core/src/main/net/dpml/magic/model/Info.java
(original)
+++ development/main/magic/core/src/main/net/dpml/magic/model/Info.java Sun
Jan 30 07:47:37 2005
@@ -55,43 +55,10 @@
final String name = artifact.getName();
final String version = artifact.getVersion();
final String type = artifact.getType();
- return create( group, name, version, type,
SNAPSHOT.equalsIgnoreCase( version ) );
-
- /*
- final int i = id.indexOf( ":" );
- if( i<0 )
- {
- final String error =
- "Missing protocol in id [" + id + "]";
- throw new BuildException( error );
- }
- final String protocol = id.substring( 0, i );
- final String spec = id.substring( i+1 );
- return Info.create( protocol, spec );
- */
+ return create( group, name, version, new String[]{ type },
SNAPSHOT.equalsIgnoreCase( version ) );
}
/**
- * Creation of a new info instance relative to a supplied home,
- * type, and artifact specification.
- * @param type the artifact type
- * @param id the artiact identifier
- * @return the immutable info descriptor
- */
- /*
- public static Info create( final String type, final String id )
- {
- final int n = getGroupIndex( id );
- final String group = getGroupFromId( id, n );
- final String name = getNameFromId( id, n );
- final String version = getVersionFromId( id );
- return Info.create(
- group, name, version, type,
- SNAPSHOT.equalsIgnoreCase( version ) );
- }
- */
-
- /**
* Creation of a new info instance relative to a supplied set of
parameters.
* @param group the artifact group
* @param name the artifact name
@@ -102,20 +69,20 @@
*/
public static Info create(
final String group, final String name, final String version,
- final String type, boolean snapshot )
+ String[] types, boolean snapshot )
{
- return new Info( group, name, version, type, snapshot );
+ return new Info( group, name, version, types, snapshot );
}
- private String m_name;
- private String m_group;
- private String m_version;
- private String m_type;
- private boolean m_snapshot;
+ private final String m_name;
+ private final String m_group;
+ private final String m_version;
+ private final String[] m_types;
+ private final boolean m_snapshot;
private Info(
final String group, final String name, final String version,
- final String type, boolean snapshot )
+ String[] types, boolean snapshot )
{
assertNotNull( "group", group );
assertNotNull( "name", name );
@@ -123,15 +90,23 @@
m_group = group;
m_name = name;
m_version = version;
- if( null == type )
+ m_types = types;
+
+ if( m_types.length < 1 )
{
- m_type = "jar";
+ final String error =
+ "At least one type is required.";
+ throw new IllegalArgumentException( error );
}
- else
+
+ m_snapshot = snapshot;
+
+ System.out.print( "## CREATED INFO " + name );
+ for( int i=0; i<m_types.length; i++ )
{
- m_type = type;
+ System.out.print( ", " + m_types[i] );
}
- m_snapshot = snapshot;
+ System.out.println(".");
}
/**
@@ -185,14 +160,42 @@
*/
public String getType()
{
- if( null == m_type )
- {
- return "jar";
- }
- else
+ return m_types[0];
+ }
+
+ /**
+ * Return a string array identifying the aritfact types.
+ * @return the artifact types
+ */
+ public String[] getTypes()
+ {
+ return m_types;
+ }
+
+ /**
+ * Return a string array identifying the aritfact types.
+ * @return the artifact types
+ */
+ public boolean isa( String type )
+ {
+ for( int i=0; i<m_types.length; i++ )
{
- return m_type;
+ if( m_types[i].equals( type ) )
+ {
+ return true;
+ }
}
+ return false;
+ }
+
+
+ /**
+ * Return the type at the supplied index position.
+ * @return the artifact type
+ */
+ public String getType( int index )
+ {
+ return m_types[ index ];
}
/**
@@ -218,10 +221,20 @@
*/
public String getFilename()
{
+ return getFilename( getType() );
+ }
+
+ /**
+ * Return the full filename of the artifact. The value returned is in the
form
+ * [name]-[version].[type] or in the case of a null version [name].[type].
+ * @return the artifact filename
+ */
+ public String getFilename( String type )
+ {
final String shortFilename = getShortFilename();
final StringBuffer buffer = new StringBuffer( shortFilename );
buffer.append( "." );
- buffer.append( getType() );
+ buffer.append( type );
return buffer.toString();
}
@@ -232,10 +245,20 @@
*/
public String getPath()
{
- final String filename = getFilename();
+ return getPath( getType() );
+ }
+
+ /**
+ * Return the path to the artifact. The path is returned in the
+ * form [group]/[type]s/[filename].
+ * @return the artifact relative path
+ */
+ public String getPath( String type )
+ {
+ final String filename = getFilename( type );
final StringBuffer buffer = new StringBuffer( getGroup() );
buffer.append( "/" );
- buffer.append( getType() );
+ buffer.append( type );
buffer.append( "s/" );
buffer.append( filename );
return buffer.toString();
@@ -293,9 +316,21 @@
*/
public String getJavadocPath()
{
+ return getJavadocPath( getType() );
+ }
+
+ /**
+ * Return the api javadoc path. The path is retured in the form
+ * /api/[group]/[version] for a module and /api/[group]/[name]/[version]
+ * for other types.
+ *
+ * @return the javadoc api path
+ */
+ public String getJavadocPath( String type )
+ {
StringBuffer buffer = new StringBuffer( "/api/" );
buffer.append( getGroup() );
- if( !"module".equals( getType() ) )
+ if( !"module".equals( type ) )
{
buffer.append( "/" + getName() );
}
@@ -306,7 +341,6 @@
return buffer.toString();
}
-
/**
* Return the artifact specification using the supplied group and
* version separators.
@@ -344,18 +378,39 @@
*/
public boolean equals( final Object other )
{
- if( ! ( other instanceof Info ) )
+ if( !( other instanceof Info ) )
+ {
return false;
+ }
final Info info = (Info) other;
if( isaSnapshot() != info.isaSnapshot() )
+ {
return false;
+ }
if( ! getName().equals( info.getName() ) )
+ {
return false;
+ }
if( ! getGroup().equals( info.getGroup() ) )
+ {
return false;
- if( ! getType().equals( info.getType() ) )
+ }
+
+ /*
+ if( getTypes().length != info.getTypes().length )
+ {
return false;
+ }
+
+ for( int i=0; i<m_types.length; i++ )
+ {
+ if( m_types[i].equals( info.getType( i ) ) )
+ {
+ return false;
+ }
+ }
+ */
if( null == getVersion() )
{
@@ -383,7 +438,11 @@
hash = hash ^ m_name.hashCode();
hash = hash ^ m_group.hashCode();
- hash = hash ^ m_type.hashCode();
+
+ for( int i=0; i<m_types.length; i++ )
+ {
+ hash = hash ^ m_types[i].hashCode();
+ }
return hash;
}
Modified:
development/main/magic/core/src/main/net/dpml/magic/model/Resource.java
==============================================================================
--- development/main/magic/core/src/main/net/dpml/magic/model/Resource.java
(original)
+++ development/main/magic/core/src/main/net/dpml/magic/model/Resource.java
Sun Jan 30 07:47:37 2005
@@ -130,6 +130,7 @@
if( "module".equals( getInfo().getType() ) )
{
ResourceRef[] implicit = getIndex().getSubsidiaryRefs( this );
+System.out.println( "#MOD " + getInfo().getName() + " contains " +
implicit.length );
ArrayList list = new ArrayList();
for( int i=0; i<implicit.length; i++ )
{
@@ -246,6 +247,7 @@
throw new NullArgumentException( "project" );
}
+System.out.println( "## PATH " + this + " with " + filter + ", " +
moduleFilter );
final Path path = new Path( project );
final ArrayList visited = new ArrayList();
final ResourceRef[] refs = getResourceRefs( project, mode,
ResourceRef.ANY, true );
@@ -258,12 +260,24 @@
if( filterModule( resource, moduleFilter ) )
{
Info info = resource.getInfo();
- String type = info.getType();
- if( ( "*".equals( filter ) || filter.equals( type ) )
- && !"".equals( type ) & !"theme".equals( type ) )
+ if( "*".equals( filter ) )
{
- final File file = resource.getArtifact( project );
- path.createPathElement().setLocation( file );
+ String[] types = info.getTypes();
+ for( int j=0; j<types.length; j++ )
+ {
+System.out.println( "## PROCESING TYPE " + types[j] );
+ final File file = resource.getArtifact( project,
types[j] );
+System.out.println( "## PROCESSED FILE" + file );
+ path.createPathElement().setLocation( file );
+ }
+ }
+ else
+ {
+ if( info.isa( filter ) )
+ {
+ final File file = resource.getArtifact( project,
filter );
+ path.createPathElement().setLocation( file );
+ }
}
}
visited.add( ref );
@@ -328,12 +342,17 @@
public File getArtifact( final Project project )
{
- return get();
+ return get( getInfo().getType() );
+ }
+
+ public File getArtifact( final Project project, String type )
+ {
+ return get( type );
}
- private File get() throws BuildException
+ private File get( String type ) throws BuildException
{
- final String path = getInfo().getURI();
+ final String path = getInfo().getURI( type );
try
{
URL url = new URL( null, path, new Handler() );
Modified:
development/main/magic/core/src/main/net/dpml/magic/project/ProjectPath.java
==============================================================================
---
development/main/magic/core/src/main/net/dpml/magic/project/ProjectPath.java
(original)
+++
development/main/magic/core/src/main/net/dpml/magic/project/ProjectPath.java
Sun Jan 30 07:47:37 2005
@@ -205,13 +205,12 @@
if( null != m_key )
{
- if( m_type.equals( def.getInfo().getType() ) )
+ if( def.getInfo().isa( m_type ) )
{
File file = getMainFile( def, m_resolve );
path.createPathElement().setLocation( file );
}
}
-
super.add( path );
m_initialized = true;
}
@@ -220,7 +219,7 @@
{
if( resolve )
{
- return resource.getArtifact( getProject() );
+ return resource.getArtifact( getProject(), m_type );
}
else
{
Modified:
development/main/magic/core/src/main/net/dpml/magic/tasks/ReactorTask.java
==============================================================================
---
development/main/magic/core/src/main/net/dpml/magic/tasks/ReactorTask.java
(original)
+++
development/main/magic/core/src/main/net/dpml/magic/tasks/ReactorTask.java
Sun Jan 30 07:47:37 2005
@@ -81,21 +81,6 @@
public void execute() throws BuildException
{
executeReactiveBuild( m_target );
- /*
- try
- {
- String key = getContext().getKey();
- getIndex().getDefinition( key );
-
- final String error =
- "Illegal attempt to execute a reactor build within a project
node.";
- throw new BuildException( error );
- }
- catch( UnknownResourceException ure )
- {
- executeReactiveBuild( m_target );
- }
- */
}
private void executeReactiveBuild( String target )
@@ -130,7 +115,6 @@
}
}
-
private List getDefinitionList()
{
final Project project = getProject();
@@ -197,6 +181,7 @@
final List definitions, final Definition def, final ArrayList done,
final ArrayList order )
{
final Definition[] providers = getProviders( definitions, def );
+
for( int i = (providers.length - 1); i > -1; i-- )
{
visit( definitions, providers[i], done, order );
Modified: development/main/magic/index.xml
==============================================================================
--- development/main/magic/index.xml (original)
+++ development/main/magic/index.xml Sun Jan 30 07:47:37 2005
@@ -68,11 +68,15 @@
<name>dpml-magic-core</name>
<version>1.0.0</version>
<status>SNAPSHOT</status>
- <type>jar</type>
+ <types>
+ <type>jar</type>
+ <type>plugin</type>
+ </types>
</info>
<dependencies>
<include key="dpml-magic-bootstrap"/>
<include key="ant-junit"/>
+ <include key="checkstyle"/>
</dependencies>
</project>
@@ -117,7 +121,7 @@
</dependencies>
</project>
-<project basedir="spells/eclipse">
+ <project basedir="spells/eclipse">
<info>
<group>dpml/magic</group>
<name>dpml-magic-eclipse</name>
@@ -130,7 +134,6 @@
</dependencies>
</project>
-
<project basedir="spells/style">
<info>
<group>dpml/magic</group>
Modified: development/main/transit/handler/build.xml
==============================================================================
--- development/main/transit/handler/build.xml (original)
+++ development/main/transit/handler/build.xml Sun Jan 30 07:47:37 2005
@@ -21,8 +21,10 @@
<project name="dpml-transit-main" default="install" basedir="."
xmlns:magic="antlib:net.dpml.magic"
xmlns:x="plugin:dpml/magic/dpml-magic-core" >
- <filter token="PROJECT-VERSION" value="${project.version}"/>
<magic:import uri="artifact:template:dpml/magic/standard"/>
+ <target name="init" depends="standard.init">
+ <filter token="PROJECT-VERSION" value="${project.version}"/>
+ </target>
</project>
Modified: development/main/transit/index.xml
==============================================================================
--- development/main/transit/index.xml (original)
+++ development/main/transit/index.xml Sun Jan 30 07:47:37 2005
@@ -20,7 +20,7 @@
<index key="dpml-transit">
- <import index="../magic/index.xml"/>
+ <!--<import index="../magic/index.xml"/>-->
<import index="../util/index.xml"/>
<!--
@@ -36,7 +36,7 @@
<type>module</type>
</info>
<plugins>
- <include key="dpml-magic-checkstyle"/>
+ <!--<include key="dpml-magic-checkstyle"/>-->
</plugins>
<dependencies>
<include key="dpml-util"/>
@@ -57,6 +57,8 @@
</info>
</project>
+ <!-- disabled pending completion of a core transit bundle relase -->
+ <!--
<project basedir="installer">
<info>
<group>dpml/transit</group>
@@ -69,6 +71,7 @@
<include key="dpml-transit-plugin"/>
</dependencies>
</project>
+ -->
<project basedir="plugin">
<info>
@@ -76,7 +79,10 @@
<name>dpml-transit-plugin</name>
<version>1.0.0</version>
<status>SNAPSHOT</status>
- <type>jar</type>
+ <types>
+ <type>jar</type>
+ <type>plugin</type>
+ </types>
</info>
<dependencies>
<include key="dpml-transit-main"/>
@@ -94,7 +100,7 @@
<info>
<group>dpml/tutorial</group>
<name>dpml-transit-tutorial-artifact</name>
- <type></type>
+ <type>NULL</type>
</info>
<dependencies>
<include key="dpml-transit-main"/>
@@ -105,7 +111,7 @@
<info>
<group>dpml/tutorial</group>
<name>dpml-transit-tutorial-extension</name>
- <type></type>
+ <type>NULL</type>
</info>
<dependencies>
<include key="dpml-transit-main"/>
@@ -116,7 +122,10 @@
<info>
<group>dpml/tutorial</group>
<name>dpml-transit-tutorial-plugin-simple</name>
- <type>jar</type>
+ <types>
+ <type>jar</type>
+ <type>plugin</type>
+ </types>
</info>
<dependencies>
<include key="dpml-transit-main"/>
@@ -127,7 +136,10 @@
<info>
<group>dpml/tutorial</group>
<name>dpml-transit-tutorial-plugin-cli</name>
- <type>jar</type>
+ <types>
+ <type>jar</type>
+ <type>plugin</type>
+ </types>
</info>
<dependencies>
<include key="dpml-transit-main"/>
@@ -139,7 +151,10 @@
<info>
<group>dpml/tutorial</group>
<name>dpml-transit-tutorial-plugin-controller</name>
- <type>jar</type>
+ <types>
+ <type>jar</type>
+ <type>plugin</type>
+ </types>
</info>
<dependencies>
<include key="dpml-transit-main"/>
Modified: development/main/transit/module.xml
==============================================================================
--- development/main/transit/module.xml (original)
+++ development/main/transit/module.xml Sun Jan 30 07:47:37 2005
@@ -22,7 +22,10 @@
xmlns:x="plugin:dpml/magic/dpml-magic-core" >
<magic:import uri="artifact:template:dpml/magic/standard"/>
- <magic:import uri="artifact:template:dpml/magic/checkstyle"/>
+
+ <target name="prepare" depends="init">
+ <filter token="PRODUCT-VERSION" value="${project.version}"/>
+ </target>
<target name="build" depends="standard.build">
<x:module index="index.xml">
@@ -38,17 +41,20 @@
</target>
<target name="install" depends="standard.install,docs">
- <property name="anchor"
value="${basedir}/target/temp/${project.version}"/>
- <mkdir dir="${anchor}"/>
- <x:path id="util.path" type="*" mode="RUNTIME" module="true"/>
- <x:replicate refid="util.path" toDir="${anchor}" />
- <x:bar>
- <fileset dir="${anchor}"/>
- </x:bar>
+ <property name="anchor"
value="${basedir}/target/local/${project.version}"/>
+ <property name="group" value="${anchor}/${project.group}"/>
+ <mkdir dir="${group}"/>
+ <x:path id="module.path" type="*" mode="RUNTIME" module="true"/>
+ <x:replicate refid="module.path" toDir="${anchor}" />
+ <copy todir="${group}">
+ <fileset dir="${basedir}/target/deliverables"/>
+ </copy>
</target>
- <target name="docs" depends="standard.install,junit-report,checkstyle">
- <x:javadoc overview="overview.html">
+ <target name="docs" depends="javadoc,junit-report"/>
+
+ <target name="javadoc" depends="build">
+ <x:javadoc overview="overview.html" title="DPML Transit API - Build
${project.version}">
<link href="http://java.sun.com/j2se/1.4/docs/api"/>
<link href="http://www.dpml.net/api/commons-cli/1.0"/>
<group title="Transit Protocol Handler">
@@ -65,7 +71,7 @@
</x:javadoc>
</target>
- <target name="junit-report">
+ <target name="junit-report" depends="test">
<mkdir dir="target/reports/junit"/>
<junitreport todir="target/reports/junit">
<fileset dir=".">
@@ -75,4 +81,70 @@
</junitreport>
</target>
+ <target name="bundle" depends="package">
+ <property name="work" value="${basedir}/target/bundle"/>
+ <delete dir="${work}"/>
+ <mkdir dir="${work}"/>
+ <!-- create the transit configuration directory -->
+ <property name="root" value="${work}/transit"/>
+ <echo>Adding Transit application properties to ${root}</echo>
+ <mkdir dir="${root}"/>
+ <copy todir="${root}">
+ <fileset dir="${basedir}/handler/target/setup"/>
+ </copy>
+ <!-- include the util package -->
+ <x:property name="util.version" id="dpml-util" feature="version"/>
+ <property name="local" value="${work}/local/${project.version}"/>
+ <echo>Creating local repository ${local}</echo>
+ <mkdir dir="${local}"/>
+ <copy todir="${local}">
+ <fileset dir="${basedir}/../util/target/local/${util.version}"/>
+ <fileset dir="${basedir}/target/local/${project.version}"/>
+ </copy>
+ <!-- create the bin directory -->
+ <property name="bin" value="${work}/bin"/>
+ <echo>Adding scripts from ${bin}</echo>
+ <mkdir dir="${bin}"/>
+ <copy todir="${bin}">
+ <fileset dir="${basedir}/plugin/target/bin"/>
+ </copy>
+ <!-- create the api doc directory -->
+ <property name="api" value="${work}/docs/api"/>
+ <echo>Adding api documentation to ${api}</echo>
+ <mkdir dir="${api}"/>
+ <copy todir="${api}">
+ <fileset dir="${dpml.docs}/api">
+ <include name="dpml/util/${util.version}/**/*.*"/>
+ <include name="dpml/transit/${project.version}/**/*.*"/>
+ </fileset>
+ </copy>
+ <!-- create the README and LICENSE files-->
+ <copy todir="${work}" filtering="true">
+ <fileset dir="${basedir}">
+ <include name="README.TXT"/>
+ </fileset>
+ </copy>
+ <copy todir="${work}">
+ <fileset dir="${basedir}/../central/license"/>
+ </copy>
+ </target>
+
+ <target name="dist" depends="install,bundle">
+ <x:dist>
+ <fileset dir="${work}">
+ <exclude name="bin/**"/>
+ </fileset>
+ <fileset dir="${work}">
+ <include name="bin/*.policy"/>
+ </fileset>
+ <zipfileset dir="${work}/bin" prefix="bin">
+ <include name="*.bat"/>
+ </zipfileset>
+ <tarfileset dir="${work}/bin" mode="755" prefix="bin">
+ <include name="transit"/>
+ <include name="*.sh"/>
+ </tarfileset>
+ </x:dist>
+ </target>
+
</project>
Modified: development/main/transit/plugin/build.xml
==============================================================================
--- development/main/transit/plugin/build.xml (original)
+++ development/main/transit/plugin/build.xml Sun Jan 30 07:47:37 2005
@@ -18,7 +18,7 @@
limitations under the License.
-->
-<project name="dpml-transit-plugin" default="dist" basedir="."
+<project name="dpml-transit-plugin" default="install" basedir="."
xmlns:magic="antlib:net.dpml.magic"
xmlns:x="plugin:dpml/magic/dpml-magic-core" >
<magic:import uri="artifact:template:dpml/magic/standard"/>
@@ -28,22 +28,22 @@
<x:filter feature="path" key="dpml-transit-main" platform="windows"
token="WINDOWS-CLI-MAIN-PATH"/>
<x:filter feature="path" key="dpml-transit-main" platform="unix"
token="UNIX-CLI-MAIN-PATH"/>
<x:filter feature="version" key="dpml-transit-main"
token="TRANSIT_VERSION"/>
- <x:filter feature="classpath" key="dpml-transit-main" platform="windows"
prefix="%DPML_CACHE%"
- token="WINDOWS-CLI-CLASSPATH"/>
- <x:filter feature="classpath" key="dpml-transit-main" platform="unix"
prefix="$DPML_CACHE"
- token="UNIX-CLI-CLASSPATH"/>
+ <x:property feature="version" key="dpml-transit-main"
name="transit.main.version"/>
+ <x:property feature="path" key="dpml-transit-main" platform="windows"
name="transit.w32.path"/>
+ <x:property feature="path" key="dpml-transit-main" platform="unix"
name="transit.unix.path"/>
+ <filter token="WINDOWS-CLI-CLASSPATH"
value="%DPML_HOME%\local\${transit.main.version}\${transit.w32.path}"/>
+ <filter token="UNIX-CLI-CLASSPATH"
value="$DPML_HOME/local/${transit.main.version}/${transit.unix.path}"/>
</target>
<target name="package" depends="standard.package">
<x:export class="net.dpml.transit.control.CommandHandler"/>
</target>
+ <!--
<target name="bin" depends="install">
<echo>
-#----------------------------------------------------------------------------------
# Updating DPML HOME bin directory.
# Directory: ${dpml.home}/bin
-#----------------------------------------------------------------------------------
</echo>
<mkdir dir="${dpml.home}/bin"/>
<copy todir="${dpml.home}/bin">
@@ -52,7 +52,9 @@
<chmod file="${dpml.home}/bin/transit" perm="755"/>
<chmod dir="${dpml.home}/bin" includes="*.sh" perm="755"/>
</target>
+ -->
+ <!--
<target name="dist" depends="bin">
<jar
jarfile="${basedir}/target/deliverables/jars/dpml-transit-LATEST.jar" >
<fileset dir="${dpml.home}" >
@@ -68,5 +70,6 @@
</fileset>
</jar>
</target>
+ -->
</project>
Modified: development/main/transit/plugin/etc/bin/transit.bat
==============================================================================
--- development/main/transit/plugin/etc/bin/transit.bat (original)
+++ development/main/transit/plugin/etc/bin/transit.bat Sun Jan 30 07:47:37
2005
@@ -16,12 +16,12 @@
:SET_METRO
if "%DPML_HOME%" == "" set DPML_HOME=%USERPROFILE%\.dpml
-if "%DPML_CACHE%" == "" set DPML_CACHE=%DPML_HOME%\cache
+if "%DPML_TRANSIT_CLASSPATH%" == "" set
DPML_TRANSIT_CLASSPATH=@WINDOWS-CLI-CLASSPATH@
if "%TRANSIT_PLUGIN%" == "" set TRANSIT_PLUGIN=@TRANSIT-PLUGIN-URI@
set CMD_LINE_ARGS=%*
set SECURITY_POLICY=-Djava.security.policy="%DPML_HOME%\bin\security.policy"
-set TRANSIT_CLASSPATH="%DPML_HOME%\transit\lib";"@WINDOWS-CLI-CLASSPATH@"
+set TRANSIT_CLASSPATH="%DPML_HOME%\transit\lib";"%DPML_TRANSIT_CLASSPATH%"
:RUN_METRO
%JAVA% %SECURITY_POLICY% %TRANSIT_JVM_OPTS%
-Ddpml.transit.bootstrap.uri=%TRANSIT_PLUGIN% -classpath %TRANSIT_CLASSPATH%
net.dpml.transit.Main -Xbootstrap=%TRANSIT_PLUGIN% %CMD_LINE_ARGS%
Modified: development/main/util/index.xml
==============================================================================
--- development/main/util/index.xml (original)
+++ development/main/util/index.xml Sun Jan 30 07:47:37 2005
@@ -2,7 +2,7 @@
<index key="dpml-util">
- <import index="../magic/index.xml"/>
+ <!--<import index="../magic/index.xml"/>-->
<!--
Metro Module
@@ -17,7 +17,7 @@
<type>module</type>
</info>
<plugins>
- <include key="dpml-magic-checkstyle"/>
+ <!--<include key="dpml-magic-checkstyle"/>-->
</plugins>
</project>
Modified: development/main/util/module.xml
==============================================================================
--- development/main/util/module.xml (original)
+++ development/main/util/module.xml Sun Jan 30 07:47:37 2005
@@ -5,19 +5,43 @@
xmlns:x="plugin:dpml/magic/dpml-magic-core">
<magic:import uri="artifact:template:dpml/magic/standard"/>
- <magic:import uri="artifact:template:dpml/magic/checkstyle"/>
<target name="build" depends="standard.build">
- <x:module index="index.xml"/>
+ <x:module index="index.xml">
+ <header>
+ <packages>
+ <package name="net.dpml.exception"/>
+ <package name="net.dpml.criteria"/>
+ <package name="net.dpml.cli"/>
+ <package name="net.dpml.i18n"/>
+ </packages>
+ <svn href="http://paris.dpml.net/svn/main/unit"/>
+ <home href="http://www.dpml.net"/>
+ </header>
+ </x:module>
</target>
- <target name="docs" depends="standard.install,junit-report,checkstyle">
- <x:javadoc overview="overview.html" title="DPML Utilities API -
${project.version}">
+ <target name="install" depends="standard.install,docs">
+ <property name="root" value="${basedir}/target/local"/>
+ <property name="anchor" value="${root}/${project.version}"/>
+ <property name="group" value="${anchor}/${project.group}"/>
+ <mkdir dir="${group}"/>
+ <x:path id="util.path" type="*" mode="RUNTIME" module="true"/>
+ <x:replicate refid="util.path" toDir="${anchor}" />
+ <copy todir="${group}">
+ <fileset dir="${basedir}/target/deliverables"/>
+ </copy>
+ </target>
+
+ <target name="docs" depends="javadoc,junit-report"/>
+
+ <target name="javadoc" depends="build">
+ <x:javadoc overview="overview.html" title="DPML Utilities API - Build
${project.version}">
<link href="http://java.sun.com/j2se/1.4/docs/api"/>
</x:javadoc>
</target>
- <target name="junit-report">
+ <target name="junit-report" depends="test">
<mkdir dir="target/reports/junit"/>
<junitreport todir="target/reports/junit">
<fileset dir=".">
@@ -27,15 +51,5 @@
</junitreport>
</target>
- <target name="install" depends="standard.install,docs">
- <property name="root" value="${basedir}/target/temp"/>
- <property name="anchor" value="${root}/${project.version}"/>
- <mkdir dir="${anchor}"/>
- <x:path id="util.path" type="*" mode="RUNTIME" module="true"/>
- <x:replicate refid="util.path" toDir="${anchor}" />
- <x:bar>
- <fileset dir="${anchor}"/>
- </x:bar>
- </target>
</project>
- svn commit: r1630 - in development/main: . magic magic/core/src/main/net/dpml/magic/builder magic/core/src/main/net/dpml/magic/model magic/core/src/main/net/dpml/magic/project magic/core/src/main/net/dpml/magic/tasks transit transit/handler transit/plugin transit/plugin/etc/bin util, mcconnell, 01/30/2005
Archive powered by MHonArc 2.6.24.