ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <lars.matts...@sungard.com>
Subject RE: Fileset
Date Fri, 19 May 2006 13:12:12 GMT
Well, almost like that, 
But if possible I would like to have the names of changed.

So, if your file set ended up being
/alpha/beta/foo.txt
/theta/epsilon/bar.txt
/here/there
/over/yonder

You'd want the zip file to contain
foo.txt
bar.txt
/newname
/over/yonder

-----Original Message-----
From: Scot P. Floess [mailto:floess@mindspring.com] 
Sent: den 19 maj 2006 14:45
To: Ant Users List
Subject: Re: Fileset

So, are u saying what you want is if a file is found in your file set, 
disregard the directory as part of the zip - and if its a directory, zip

everything in the directory?

So, if your file set ended up being
/alpha/beta/foo.txt
/theta/epsilon/bar.txt
/here/there
/over/yonder

You'd want the zip file to contain
foo.txt
bar.txt
/here/there
/over/yonder



lars.mattsson@sungard.com wrote:
> Hello I want to create an Zip file with the zip and fileset tasks. The
> problem I'm having is that it puts all files in the root directory.
>
> <?xml version="1.0" encoding="utf-8" ?> 
> <project basedir="." default="all" name="name">
>  
>    <target name="dtCompass-dist"> 
>         <zip destfile="Demo.zip">
> 			<fileset dir="..\..\..\program\bin"/ >
> 			<fileset dir="..\..\..\program2\bin"/>
> f
> 			<fileset dir="..\bin"/>
> 			<fileset dir="dir1" />
> 			<fileset dir="dir2" />
> 			<fileset dir="test" />
> 		</zip>
>    </target>
>    
>    <target name="all" depends="dtCompass-dist"/>
>    
> </project>
>
> The files as said get's at the root of each of the filesets.
>
> I instead would want the each of the included directories be an own
> directory and under a other name. Something like this:
>
> ZipFile:
> <dir> program   - Removed the \bin as well and replaced it with
program
> name
> <dir> program2  - Removed the \bin and replaced with program2 name
> <dir> dir1
> <dir> dir2
> <dir> test
>
>
> Is there a target for the fileset I can use or another task?
>
> Lars
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
>
>   

-- 
Scot P. Floess
27 Lake Royale
Louisburg, NC  27549

252-478-8087 (Home)
919-754-4592 (Work)

Chief Architect JPlate  http://sourceforge.net/projects/jplate
Chief Architect JavaPIM http://sourceforge.net/projects/javapim


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message