On Wed, 10 Sep 2008, Hans Schwaebli <[EMAIL PROTECTED]> wrote: > I want to unzip a part of the zip file. > > For example in the zipfile there are these folders: > > -a > -b > -c > -d > -e > -f > > I want just folder "e" to export. But if I do, then it creates the > whole structure in the output folder: > > -a > -d > -e > > I use: > > <unzip src="zipfile.zip" dest="c:/tmp"> > <patternset> > <include name="/**/e/**/*"/> > </patternset> > </unzip> > > Moving and deleting folders afterwards is a workaround. Is there any > real solution in Ant for this?
Yes, add a mapper to the task, something like (untested) <unzip src="zipfile.zip" dest="c:/tmp"> <patternset> <include name="/**/e/**/*"/> </patternset> <regexpmapper from=".*/e/(.*)" to="e/\1"/> </unzip> Stefan --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]