Stores the size of a specified file in a property. The file size is returned in
bytes.
Table C.10: Attributes
Name | Type | Description | Default | Required |
---|
file | String | Filename | n/a | Yes |
propertyname | String | Name of property where the file size is stored | filesize | No |
<filesize file="${builddir}/${tarball}.tar.${compression}" />
<php expression="floor(${filesize}/1024)" returnProperty="ksize" />
<php expression="floor(${filesize}/1024/1024)" returnProperty="msize" />
<echo msg="Filesize is: ${ksize} kB"/>
<echo msg="Filesize is: ${msize} MB"/>