You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Colin Fleming <co...@gmail.com> on 2007/08/30 22:49:18 UTC

Problem with subant and genericantfile

Hi all,

I'm in the process of rewriting our build using Ivy, and I'm having a
problem with Subant. Ivy is usually used by calling the ivy:buildlist task
which returns a filelist of files sorted in dependency order. These are
normally build files, so the idea is that you then use subant to call them
all. I'd like to use the genericantfile option with subant, so I'd like to
convert my filelist into a path containing the directory of each file in the
filelist, but for the life of me I can't figure out how I might do it. Is
this possible?

Thanks for any help,
Colin
-- 
View this message in context: http://www.nabble.com/Problem-with-subant-and-genericantfile-tf4356846.html#a12415896
Sent from the Ant - Users mailing list archive at Nabble.com.


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


Re: Problem with subant and genericantfile

Posted by Dominique Devienne <dd...@gmail.com>.
On 8/30/07, Colin Fleming <co...@gmail.com> wrote:
> Well, actually Ivy is creating a list of files that currently exist since
> I'm currently following your second suggestion, having tiny build files in
> each module that include the common one. I'd rather get rid of that since
> people are showing an annoying tendency to fiddle with them, and in build of
> 80+ modules it's hard to figure out what's going on when they do :-)

Sounds like you're in charge of CM, so you also probably manage the
SCM repo, and could add triggers to only allow CM guys to check in
build.xml files ;-) --DD

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


Re: Problem with subant and genericantfile

Posted by Colin Fleming <co...@gmail.com>.
Hi Dominique,

Thanks for the prompt reply!


Dominique Devienne-2 wrote:
> 
> I'm surprised Ivy would build a file list of non-existent files, which
> I surmise from you wanting to use genericantfile.
> 


Dominique Devienne-2 wrote:
> 
> Personally I prefer to have a tiny build file in all sub-projects,
> which imports the common build, rather than using genericantfile.
> Would avoid your issue altogether ;-) --DD

Well, actually Ivy is creating a list of files that currently exist since
I'm currently following your second suggestion, having tiny build files in
each module that include the common one. I'd rather get rid of that since
people are showing an annoying tendency to fiddle with them, and in build of
80+ modules it's hard to figure out what's going on when they do :-)

Looks like a job for a custom task to me.

Thanks,
Colin
-- 
View this message in context: http://www.nabble.com/Problem-with-subant-and-genericantfile-tf4356846.html#a12416533
Sent from the Ant - Users mailing list archive at Nabble.com.


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


Re: Problem with subant and genericantfile

Posted by Dominique Devienne <dd...@gmail.com>.
On 8/30/07, Colin Fleming <co...@gmail.com> wrote:
> I'm in the process of rewriting our build using Ivy, and I'm having a
> problem with Subant. Ivy is usually used by calling the ivy:buildlist task
> which returns a filelist of files sorted in dependency order. These are
> normally build files, so the idea is that you then use subant to call them
> all. I'd like to use the genericantfile option with subant, so I'd like to
> convert my filelist into a path containing the directory of each file in the
> filelist, but for the life of me I can't figure out how I might do it. Is
> this possible?

I'm surprised Ivy would build a file list of non-existent files, which
I surmise from you wanting to use genericantfile. No, I also don't see
a way to transform a file list into a list of these files' parent dir.
The new resource collections stuff allow re-ordering and filtering of
resources, but I don't see a way to "map" a resource to another
(typically with a mapper). Mappers have traditionally been used at the
task level, not the resource collection level, and subant doesn't seem
to support it.

That's the kind of thing I'd have written a <script> for, in
JavaScript, but there's a lot of trial-and-error doing such things
usually (when something goes wrong with the script, not easy to
troubleshoot it).

Personally I prefer to have a tiny build file in all sub-projects,
which imports the common build, rather than using genericantfile.
Would avoid your issue altogether ;-) --DD

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