commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Commons Wiki] Update of "ExtractAndDecompressGzipFiles" by KenTanaka
Date Tue, 06 Nov 2007 22:13:49 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Commons Wiki" for change notification.

The following page has been changed by KenTanaka:
http://wiki.apache.org/jakarta-commons/ExtractAndDecompressGzipFiles

The comment on the change is:
Initial content

New page:
Try using VFS to read the content of a compressed (gz) file inside of a tar file. Extract
tar file objects. If they are gzip files, decompress them. Any directory structure in the
tarfile is not being preserved, the contents are pulled out to the same location regardless
of directory hierarchy (for the purposes of this example, all objects in the tar file have
unique names, so there are no file name conflicts).

Use a multiple step approach.
 1. extract gzipped file from tar file
 2. decompress gzipped content to a temporary directory
 3. move decompressed content to desired destination
 4. remove temporary directory
 5. remove gzipped file

There should be a cleaner, more direct route. Maybe someone more familiar with VFS can post
better code.

This example uses Maven2. There is a pom.xml to define the project

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message