When CruiseControl runs your build script (Ant or Maven), it passes some information in the form of system properties to the script. These can be accessed in your script like any other property, using the syntax ${propertyname}.
Here's a list of all the properties that are available to your script:
| Property Name |
Description |
| label |
The build label determined by the labelincrementer |
| cvstimestamp |
Timestamp that indicates when the build started, using the format yyyy-MM-dd HH:mm:ss 'GMT' so it can be used as a CVS argument |
| cctimestamp |
Timestamp that indicates when the build started, using the format yyyyMMddHHmmss |
| cclastgoodbuildtimestamp |
Timestamp that indicates when the last succesful build was run, using the format yyyyMMddHHmmss |
| cclastbuildtimestamp |
Timestamp that indicates when the last build was run, using the format yyyyMMddHHmmss |
| lastbuildsuccessful |
indicates if the last build was successful; either "true" or "false" |
If you're using the property or propertyondelete attributes that are available on some of the <modificationset> child-elements, the properties specified by the attribute values will also be passed to your script.
Some of these so-called SourceControls also add some specific properties of their own. This is rarely used, probably because it is a little-known feature to most developers that create a SourceControl. Here's a list for all SourceControls that add extra properties.
| SourceControl name |
Property Name |
Description |
| buildstatus |
most.recent.logdir |
The location being checked for new log files |
| buildstatus |
most.recent.logfile |
The name of the newest logfile included in the modification set |
| buildstatus |
most.recent.logtime |
The timestamp of the newest build included in the modification set, using the format yyyyMMddHHmmss |
| buildstatus |
most.recent.loglabel |
The label of the newest build included in the modification set |
| clearcase |
clearcaselastbuild |
Timestamp representing the last built time, using the format dd-MMMM-yyyy.HH:mm:ss |
| clearcase |
clearcasenow |
Timstamp representing the time the current build started, using the format dd-MMMM-yyyy.HH:mm:ss |