Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » [Acceleo] Create Standalone application
[Acceleo] Create Standalone application [message #909092] Thu, 06 September 2012 14:18 Go to next message
Luke Mising name is currently offline Luke Mising nameFriend
Messages: 7
Registered: October 2010
Junior Member

I'm trying to create a standalone application with acceleo. When running acceleo in eclipse everything works fine. But as soon as I try to export my project as a "runnable jar" file the applications crashes with the well known error ".emtl" not found. It seems that the export command does not pack the .emtl-files inside the jar??

However, now I'm trying to create my jar file with an ant-script. This seems to work fine. I just need to overwrite the method
    protected URI createTemplateURI(String entry) {    	
    	return URI.createURI(URI.decode(entry));
to tell acceleo to load the .emtl-files from inside the jar file. The execution fails with the error message "org.eclipse.acceleo.engine.AcceleoEvaluationException: Error while resolving module dependencies". Okay. Fine. Acceleo doesn't seem to like One-Jar-Applications. So my quenstion is: What is the best way to deploy an acceleo code generator as a standalone application?
Re: [Acceleo] Create Standalone application [message #909114 is a reply to message #909092] Thu, 06 September 2012 15:08 Go to previous message
Stephane Begaudeau is currently offline Stephane BegaudeauFriend
Messages: 430
Registered: April 2010
Location: Nantes (France)
Senior Member


You shouldn't have to do anything special, if you look at this test of ours, you should find everything you need:
We have a stand alone generator in the "generators" folder, the dependencies in the "lib" folder and we launch it with this class:


Stephane Begaudeau, Obeo

Twitter: @sbegaudeau & @acceleo
Google+: stephane.begaudeau & acceleo
Acceleo Documentation:

Previous Topic:migrating from acceleo2 to acceleo 3
Next Topic:[Xtend]Allow user to add code in generated source
Goto Forum:

Current Time: Sun Oct 04 19:38:33 GMT 2015

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

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