Skip to content

Latest commit

 

History

History
18 lines (14 loc) · 579 Bytes

README.md

File metadata and controls

18 lines (14 loc) · 579 Bytes

phing-datetime

DateTimeTask is a Phing extension which aims to provide the same functionality as tstamptask and to extend it with datetime->add and datetime-sub operations.

Example

<!-- remove tar-files older then DateInterval (7 days) -->
<datetime>
    <interval property="expire_date" pattern="Y-m-d" operation="sub" interval="P7D" locale="nl_NL"/>
</datetime>

<delete verbose="true">
    <fileset dir="foo" includes="**/*.tar">
        <date datetime="${expire_date}" when="before"/>
    </fileset>
</delete>