Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » [MWE2] How to run from command line?
[MWE2] How to run from command line? [message #546510] Tue, 13 July 2010 08:43 Go to next message
Eclipse UserFriend
Originally posted by: dhendriksREMOVE_THIS.tueREMOVE.THIS.nl

Hello all,

somehow I can't figure out the proper way to run an MWE2 from the
command line on my Linux system, using Eclipse Helios:

java -Xms128m -Xmx1024m -XX:MaxPermSize=256m -jar
/local/dhendriks/eclipse/plugins/org.eclipse.equinox.launche r_1.1.0.v20100507.jar
-nosplash -application org.eclipse.emf.mwe2.launch.runtime.Mwe2Runner
<absolute path to my mwe2 file parent dir>/GenerateCifText.mwe2

When I execute this line from the command line, it thinks for about a
second and then returns to the prompt. There is no output, and it didn't
generate the code using the xtext file (that's what the MWE2 is supposed
to do).

Obviously everything works just fine from Eclipse UI.

Does anyone know what I'm doing wrong?

Thanks,
Dennis
Re: [MWE2] How to run from command line? [message #547163 is a reply to message #546510] Thu, 15 July 2010 18:17 Go to previous messageGo to next message
Michael Scharf is currently offline Michael ScharfFriend
Messages: 301
Registered: July 2009
Senior Member
Hi Dennis,

maybe this helps:
http://zarnekow.blogspot.com/2010/06/how-to-deploy-xtext-sta ndalone.html

Michael


> Hello all,
>
> somehow I can't figure out the proper way to run an MWE2 from the command line on my Linux system, using Eclipse Helios:
>
> java -Xms128m -Xmx1024m -XX:MaxPermSize=256m -jar /local/dhendriks/eclipse/plugins/org.eclipse.equinox.launche r_1.1.0.v20100507.jar -nosplash -application org.eclipse.emf.mwe2.launch.runtime.Mwe2Runner <absolute path to my mwe2 file parent
> dir>/GenerateCifText.mwe2
>
> When I execute this line from the command line, it thinks for about a second and then returns to the prompt. There is no output, and it didn't generate the code using the xtext file (that's what the MWE2 is supposed to do).
>
> Obviously everything works just fine from Eclipse UI.
>
> Does anyone know what I'm doing wrong?
>
> Thanks,
> Dennis


--
Michael Scharf
Wind River Systems GmbH
http://www.WindRiver.com
http://MichaelScharf.blogspot.com/
Re: [MWE2] How to run from command line? [message #547215 is a reply to message #547163] Fri, 16 July 2010 00:55 Go to previous messageGo to next message
Michael Scharf is currently offline Michael ScharfFriend
Messages: 301
Registered: July 2009
Senior Member
On 15.07.2010 20:17, Michael Scharf wrote:
> Hi Dennis,
>
> maybe this helps:
> http://zarnekow.blogspot.com/2010/06/how-to-deploy-xtext-sta ndalone.html

Unfortunately, this procedure does not work (for me). The problem is that
some emf code needs some properties form a plugin.properties file:
ERROR eclipse.emf.mwe.core.WorkflowRunner
- The string resource '_UI_DiagnosticRoot_diagnostic' could not be located

So, the trick is to add a plugin.properties to the generated .jar file that
fixes the problem.

I use 7zip to add a .properties file.

I generate the plugin.properties file by:

- do the export above but this time I select
"Copy the required file into a sub-folder next to the generated JAR"
- then I extract all jar files (using 7zip) into one folder but
with auto-rename all duplicate files
- cat all plugin*.properties file into one

I hope this helps

Michael

--
Michael Scharf
Wind River Systems GmbH
http://www.WindRiver.com
http://MichaelScharf.blogspot.com/
Re: [MWE2] How to run from command line? [message #547246 is a reply to message #547215] Fri, 16 July 2010 06:01 Go to previous message
Eclipse UserFriend
Originally posted by: dhendriksREMOVE_THIS.tueREMOVE.THIS.nl

Hello,

some more searching turned up
http://blogs.itemis.de/feltes/2010/07/02/how-to-run-xtext-an d-other-mwe2-workflows-with-ant/,
which refers to the
http://zarnekow.blogspot.com/2010/06/how-to-deploy-xtext-sta ndalone.html
page, and explains how to do xtext/mwe2 from Ant scripts. It worked for me.

Dennis


Michael Scharf wrote:
> On 15.07.2010 20:17, Michael Scharf wrote:
>> Hi Dennis,
>>
>> maybe this helps:
>> http://zarnekow.blogspot.com/2010/06/how-to-deploy-xtext-sta ndalone.html
>
> Unfortunately, this procedure does not work (for me). The problem is that
> some emf code needs some properties form a plugin.properties file:
> ERROR eclipse.emf.mwe.core.WorkflowRunner
> - The string resource '_UI_DiagnosticRoot_diagnostic' could not be
> located
>
> So, the trick is to add a plugin.properties to the generated .jar file that
> fixes the problem.
>
> I use 7zip to add a .properties file.
>
> I generate the plugin.properties file by:
>
> - do the export above but this time I select
> "Copy the required file into a sub-folder next to the generated JAR"
> - then I extract all jar files (using 7zip) into one folder but
> with auto-rename all duplicate files
> - cat all plugin*.properties file into one
>
> I hope this helps
>
> Michael
>
Previous Topic:[Xpand] Controlling Whitespaces
Next Topic:[JET]How to compile JET templates headless using ANT
Goto Forum:
  


Current Time: Sat Apr 20 00:31:44 GMT 2024

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

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

Back to the top