Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Generation build.xml programatically
Generation build.xml programatically [message #336726] Mon, 29 June 2009 13:15 Go to next message
Aakash Murari is currently offline Aakash Murari
Messages: 2
Registered: July 2009
Junior Member
Hi

I want to build Eclipse projects in continous integration. For that, I
need to generated the build.xml programatically everytime.

I have read about the eclipse.buildScript target, but it seems is only for
plugins/features/fragments. I am having normal Java projects.

Is there any way to do it?

Thanks,
Aakash
Re: Generation build.xml programatically [message #336730 is a reply to message #336726] Mon, 29 June 2009 16:07 Go to previous messageGo to next message
Jon Svede is currently offline Jon Svede
Messages: 83
Registered: July 2009
Member
Can you explain the need to generate a build.xml each time you start a
continuous integration cycle?
Re: Generation build.xml programatically [message #336735 is a reply to message #336730] Tue, 30 June 2009 00:58 Go to previous messageGo to next message
Aakash Murari is currently offline Aakash Murari
Messages: 2
Registered: July 2009
Junior Member
We first export the ant build file, by Right click on project -> Export ->
Ant build file. Then the ant "build" target is called from our continuous
integration script.

If something leads to a change in the .classpath file, like adding an
external jar, the build.xml becomes outdated and this leads to an error in
continuous integration.

Thanks
Re: Generation build.xml programatically [message #336751 is a reply to message #336726] Tue, 30 June 2009 21:59 Go to previous message
Eclipse User
Originally posted by: eclipse-news.rizzoweb.com

Aakash Murari wrote:
> Hi
>
> I want to build Eclipse projects in continous integration. For that, I
> need to generated the build.xml programatically everytime.

By "everytime" do you mean every time a file in the project is changed
(or a subset of files)? If so, then I would use an
IResourceChangeListener and in response to changes call whatever API is
necessary to do the build.xml export.
This should help get you started:
http://www.eclipse.org/articles/Article-Resource-deltas/reso urce-deltas.html

To discover the API you need to call for the export, open the buildfile
export wizard and then use the Plug-in Spy (Shift+Alt+F1) to learn what
class implements that wizard.

Hope this helps,
Eric
Previous Topic:I found a bug, not sure what todo
Next Topic:install documentation
Goto Forum:
  


Current Time: Fri Jul 25 12:11:39 EDT 2014

Powered by FUDForum. Page generated in 0.01603 seconds