ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dona...@apache.org
Subject cvs commit: jakarta-ant/proposal/myrmidon/src/make sample.ant sample.xmk
Date Tue, 20 Feb 2001 06:12:01 GMT
donaldp     01/02/19 22:12:01

  Added:       proposal/myrmidon/src/make sample.ant
  Removed:     proposal/myrmidon/src/make sample.xmk
  Log:
  Changed sample file extentnion to .ant
  
  Revision  Changes    Path
  1.1                  jakarta-ant/proposal/myrmidon/src/make/sample.ant
  
  Index: sample.ant
  ===================================================================
  <?xml version="1.0"?>
  
  <!--
  ==============================================================================
  
   Sample build file
  
  Authors:
   Peter Donald <donaldp@apache.org>
  
  Legal:
    Copyright (c) 2000 The Apache Software Foundation. All Rights Reserved.
  
  ==============================================================================
  -->
  
  <project name="MySample" default="main" basedir=".">
  
    <property name="year" value="2000"/>
  
    <target name="main" depends="property-test" />
  
    <target name="no-test-target" unless="do-tests">
      <echo message="No tests done here"/>
    </target>
  
    <target name="test-target" depends="no-test-target" if="do-tests">
  
      <echo message="Tests away"/>
  
      <prim-test
          integer="1"
          integer2="2"
          short="3"
          short2="4"
          long="5"
          long2="6"
          byte="7"
          byte2="8"
          string="aString"
          float="1.0"
          float2="2.0"
          double="3.0"
          double2="4.0"
       />
  
      <sub-elements-test>
        <create-beep message="Evaluation of ant.install.dir=${ant.install.dir}" />
        <add-beep message="Evaluation of ant.install.lib=${ant.install.lib}" />
      </sub-elements-test>
  
      <conf-test message="Test of configuration=${ant.install.lib}" />
      
      <content-test>123</content-test>
      
    </target>
  
    <target name="property-test" depends="test-target">
      <property name="blah" value="fred" />
      <property name="${blah}" value="barney" />
  
      <register-tasklet lib="../../dist/lib/core.tsk" 
                        name="echo2" 
                        classname="org.apache.ant.modules.basic.Echo" />
  
  <!--    
      <register-tasklib lib="../../dist/lib/core.tsk" />
      <register-converter classname="org.apache.ant.modules.basic.StringToClassConverter"
                          source-type="java.lang.String"
                          destination-type="java.lang.Class"
                          lib="../../dist/lib/core.tsk" />
  -->
  
      <echo message="Doing the funky Echo with ${blah} ${fred} Year=${year}!"/>
      <echo2 message="Luke to Echo base. Can you hear me?"/>
  
      <ant-call target="property-test2">
        <param name="blah" value="blah-value" />
      </ant-call>
  
      <property name="foo">
        <pattern name="*.java"/>
      </property>
  
      <echo message="foo=${foo}" />
  
      <register-datatype lib="../../dist/lib/core.tsk" 
                         name="pattern2"
                         classname="org.apache.ant.modules.basic.Pattern" />
  
      <property name="foo2">
        <pattern2 name="*.java"/>
      </property>
  
      <echo message="foo2=${foo2}" />
  
    </target>
  
    <target name="property-test2">
      <echo message="This should fail ...."/>
      <echo message="${blah}"/>
      <echo message="Whoa - it no fail. Did you use ant-call to call me and set param blah?"/>
    </target>
  
  </project>
  
  

Mime
View raw message