try {
OutputStream out = openOutputStream(distOutputFile);
GZIPOutputStream gzip = new GZIPOutputStream(out);
String prefix = getBaseName(distOutputFile.getPath());
tar = new TarArchiveOutputStream(gzip);
TarFunction tarfun = new TarFunction(distDir, prefix, tar);
IOFileFilter uninstallFilter = new NotFileFilter(new NameFileFilter("uninstall"));
Collection<File> files = listFiles(distDir, TrueFileFilter.TRUE, uninstallFilter, true);
Collection<String> tarred = Collections2.transform(files, tarfun);
fireTransform(tarred);
} finally {