## GZip/BZip2

### Description

Packs a resource using the GZip or BZip2 algorithm. The output file is only generated if it doesn't exist or the source resource is newer.

### Parameters

Attribute | Description | Required
src | the file to gzip/bzip. | Yes, or a nested resource collection.
destfile | the destination file to create. | Exactly one of the two.
zipfile | the deprecated old name of destfile.

#### any resource or single element resource collection

The specified resource will be used as src. Since Apache Ant 1.7

### Examples

>     <gzip src="test.tar" destfile="test.tar.gz"/>

>     <bzip2 src="test.tar" destfile="test.tar.bz2"/>

>     <gzip destfile="archive.tar.gz">
>       <url url="http://example.org/archive.tar"/>
>     </gzip>

downloads http://example.org/archive.tar and compresses it to archive.tar.gz in the project's basedir on the fly.