ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hakan Koseoglu" <hakan.koseo...@pcmsgroup.com>
Subject Re: STCheckout task - checking against a timestamp
Date Thu, 05 Jun 2003 16:37:57 GMT
Hi,

Current fix is as follows:

I have a time stamp target on my top level build.xml file.

   <tstamp>
      <format property="nowstamp" pattern="yyyyMMddHHmmss" locale="en"/>
      <format property="ststamp"  pattern="MM/dd/yy hh:mm aa"/>
   </tstamp>

The first one is for the labels and the second one is for the checkouts.

On the lower level build.xml files, I have my checkout task which goes like
this:

  <target name="checkout">
    <echo message="ststamp ${ststamp}"/>
    <exec executable="java" failonerror="yes">
       <arg line="com.starbase.starteam.commandline.StarTeamCmd co -p
&quot;${st
arteam.user}:&quot;&quot;@${starteam.server}/${PROJECT}&quot; -rp ${PROJE
CT.ROOT}/${HOME} -is -o -x -eol on -cfgd &quot;${ststamp}&quot; ;"/>
    </exec>
   </target>

And the labels go in as such:

 <target name="project.label">
    <echo message="Label should be  ${label} with ${nowstamp}"/>
    <stlabel
             URL="${starteam.server}/${PROJECT}"
             username="${starteam.user}"
             password="${starteam.password}"
             label="${label}"
             lastbuild="${nowstamp}"
             description="Build timestampt at ${nowstamp} for ${label}"
   />
  </target>

Since the whole thing is parameterized, it is easy to implement accross my
30 or so projects which is collected in two CruiseControl projects (there
are dependencies between projects and branches).
Although the timestamp properties are different, since it happens in a
single tstamp task, I hope they will be identical (or close to each other in
miliseconds).

Best regards,

Hakan


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message