Skip to main content



      Home
Home » Modeling » TMF (Xtext) » Action during start of Xtext Project(Action during start of Xtext Project)
Action during start of Xtext Project [message #1741445] Thu, 25 August 2016 04:28 Go to next message
Eclipse UserFriend
Is it possible to programmatically trigger a Clean build during the start of an XText project, when i open the project in Eclipse. However i don't want to trigger the same during save of every file.
Re: Action during start of Xtext Project [message #1741448 is a reply to message #1741445] Thu, 25 August 2016 05:08 Go to previous messageGo to next message
Eclipse UserFriend
if you open a closed project that should happen anyway. can you give more details please
Re: Action during start of Xtext Project [message #1741543 is a reply to message #1741448] Thu, 25 August 2016 13:46 Go to previous messageGo to next message
Eclipse UserFriend
Thanks Christian for your quick reply.
Yes when we close and open the project eclipse automatically calls a rebuild.
However , when i open the eclipse with a already opened XText project , then eclipse skips the clean build step. So I just wanted to know whether we can some how call clean build from within our Xtext project programmatically in this case.
Re: Action during start of Xtext Project [message #1741544 is a reply to message #1741543] Thu, 25 August 2016 13:48 Go to previous messageGo to next message
Eclipse UserFriend
I do not really have an idea for that
Re: Action during start of Xtext Project [message #1742505 is a reply to message #1741543] Fri, 02 September 2016 09:24 Go to previous message
Eclipse UserFriend
Sonia Ravindran wrote on Thu, 25 August 2016 17:46
Thanks Christian for your quick reply.
Yes when we close and open the project eclipse automatically calls a rebuild.
However , when i open the eclipse with a already opened XText project , then eclipse skips the clean build step. So I just wanted to know whether we can some how call clean build from within our Xtext project programmatically in this case.


Sonia,

could you please elaborate why do you need to clean and rebuild the opened projects after application startup?

By the way, if you just want to perform an arbitrary action at startup time/workbench creation, you could look into the org.eclipse.ui.startup extension point, or if you have your own org.eclipse.equinox.app.IApplication implementation, maybe you could also check the org.eclipse.ui.application.WorkbenchWindowAdvisor#postWindowOpen() method.

If you would like to programmatically trigger a build, you could use something like this:
ResourcesPlugin.getWorkspace().getRoot().getProject("yourProjectName").build(IncrementalProjectBuilder.FULL_BUILD, new NullProgressMonitor());
Previous Topic:Add external Jar to Gradle Build in Eclipse
Next Topic:The method x() of type y must override a superclass method
Goto Forum:
  


Current Time: Sat Jul 05 07:59:14 EDT 2025

Powered by FUDForum. Page generated in 0.25813 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top