Re: 'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread Tim Visher
Sent: Monday, June 16, 2008 11:52 AM > To: Ant Users List > Subject: Re: 'clean' target specifying all files 'except' a given > fileset > > ... > As someone already said and I hinted at: It is a bit dangerous to > specify a and hope you're somehow you

RE: 'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread Vallon, Justin
id Weintraub [mailto:[EMAIL PROTECTED] Sent: Monday, June 16, 2008 11:52 AM To: Ant Users List Subject: Re: 'clean' target specifying all files 'except' a given fileset ... As someone already said and I hinted at: It is a bit dangerous to specify a and hope you're somehow you

Re: 'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread David Weintraub
You have "src/**/*" instead of just "src/**". I believe they both mean the same, but I can't say for certain. The "**" means all the files in the current directory and all files in the subdirectories too. You can have something like this: which will exclude all files in all directories with th

Re: 'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread Peter Reilly
This would work. However, it it very dangerous, it it too easy to delete stuff that you do not wont to. I would place *all* the generated artifacts of a build in a special directory - "build" or "target", and for the clean target, simply delete that directory. Peter On Mon, Jun 16, 2008 at 4

Re: 'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread Tim Visher
Hey David, Thanks for the help. This is the final copy, and it appears to be working. I had to add the /* to the end of the directories to get the actual files under those d

Re: 'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread David Weintraub
One more thing I just noticed (bad eyesight due to staring at computer screens for way too long), You have just "src/*" and "test/*". You probably want "src/**" and "test/**". A single asterisk means just the current directory. A double asterisk means all subdirectories too. -- David Weintraub [EM

Re: 'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread David Weintraub
Built a quick test myself: This works great -- except it doesn't delete directories. Filesets delete files, not directories. However, adding a "includeemptydirs" parameter to the delete task seems to do the

Re: 'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread Tim Visher
Partially solved my own problem at this point. No longer getting NullPointer but I still can't get the right includes. My syntax must be off or something. Good news is that the exclude seems to be working. Current target contents:

'clean' target specifying all files 'except' a given fileset

2008-06-16 Thread Tim Visher
Hey Everyone, I'm trying to develop a clean target that essentially deletes everything but a given set of files, rather than explicitly specifying everything to delete. This seems like a slightly more elegant solution than the alternative, but I'm having very little success at the moment. I've i