How to run pre-build commands in the Eclipse IDE

Posted by ruan007 on 05-Jul-2010 00:51

Hi,

Is there a way (or plugin) to run pre-build commands/events in OEA before compiling/running the ABL application? Currently, I have to manually run a batch file (dos commands) to create some resource files which my application requires at run-time.

Thanks in advance.

All Replies

Posted by Ravi Sankar on 05-Jul-2010 02:28

OEA uses _idecompile.p file to compile the files. This file is located @ DLC/oeide/eclipse/plugins/com.openedge.pdt.project* folder in 102B and DLC/oeide/architect/eclipse/plugins/com.openedge.pdt.text folder* in 102A/101C. You may customize it to suit your needs.

Hope this helps!

Regards,
Ravi.

Posted by Admin on 05-Jul-2010 02:44

Does that run for every individual compile job or is there a place for the beginning and end of the projects build?

Posted by Ravi Sankar on 05-Jul-2010 03:53

It runs for every individual file compile.

Another way is to listen to the AVM events using _idestartup.p "before-compile" and "after-compile" events are published for every file that is compiled. This way you don't have to modify the compilation program shipped with Architect. See documentation section OpenEdge Architect Guide > Customization > Tasks for more information on using _idestartup.

Thanks,
Ravi.

Posted by ruan007 on 05-Jul-2010 06:59

hmm, ideally, i would like the pre-build commands run once in project level, not in each file level. Looks like I have to bear it, it's still better than none.

Thanks Guys

Posted by Ravi Sankar on 05-Jul-2010 07:14

May be you can run the procedure file when the AVM starts? This way the same settings will be applicable as long as the AVM is not restarted. You could use _idestartup.p for this purpose.

Posted by Admin on 05-Jul-2010 16:14

Are you running the DOS script actually from the command prompt? Consider running it from the External Tools dialog. Then the output of that script can also be shown in the Console view of OpenEdge Architect. Many tools do actually format error messages in red color.

Posted by ruan007 on 06-Jul-2010 00:20

Aha, I think the External Tools is more suitable in my situation, I can pass arguments to the .bat file too. So no need to twist _idestartup.p.

Thank you

Posted by Admin on 06-Jul-2010 00:52

I can pass arguments to the .bat file too. So no need to twist _idestartup.p.

Indeed another great argument for external tools.

This thread is closed