diff --git a/WHATSNEW b/WHATSNEW index 0a785878e..f7042cb1a 100644 --- a/WHATSNEW +++ b/WHATSNEW @@ -836,6 +836,9 @@ Other changes: arbitrary JDBC connection properties. Bugzilla Report 33452. + * A new islastmodified condition can check the last modified date of + resources. + Changes from Ant 1.7.0 TO Ant 1.7.1 ============================================= diff --git a/docs/manual/CoreTasks/conditions.html b/docs/manual/CoreTasks/conditions.html index e49c07f92..e0ad40caf 100644 --- a/docs/manual/CoreTasks/conditions.html +++ b/docs/manual/CoreTasks/conditions.html @@ -1007,5 +1007,55 @@ is redundant and will be ignored.
+ +<hasfreespace partition="c:" needed="100M"/>
Tests the last modified date of a resource. Since Ant +1.8.0
+ +Attribute | +Description | +Required | +
millis | +Specifies the expected modification time of the resource + in milliseconds since midnight Jan 1 1970. | +Exactly one of the + two. | +
datetime | +Specifies the expected modification time of the + resource. The special value "now" indicates the + current time. | +|
pattern | +SimpleDateFormat-compatible pattern string. + Defaults to MM/DD/YYYY HH:MM AM_or_PM or MM/DD/YYYY HH:MM:SS AM_or_PM. + | +No | +
mode | +How to compare the timestamp. Accepted values + are "equals", "before", "not-before", "after" and "not-after". + | No, defaults to "equals". | +
The actual resource to test is specified as a nested element.
+ ++ An example: +
++<islastmodified dateTime="08/18/2009 04:41:19 AM" mode="not-before"> + <file file="${file}"/> +</islastmodified> +