Code generation for Language in command line

Hello guys! :)

I have build.xml for ant. And it works fine to build Language plugin. But it requires that first I run code generation in MPS. Can I generate code for my Language in command line? It needs to build project without classes_gen source_gen etc

3 comments

Can you show the structure of your BuildProject?

To build the languages from console, use an ant script with a BuildMps_Group containing all the needed languages:

idea plugin myLanguages
...
content:
myMpsGroup

mps group myMpsGroup
language ...

With this, ant builds all the referenced languages which can be used in the layout section in the same or depending BuildProject:

default layout:
zip myLanguages.zip
plugin myLanguages
0

Hello Holger!

build project looks like the picture below. Ant builds plugin if there are source_gen files. But I want it to build without generated file. That is they also should be generated from command line.

 

Ant 

0

Hello Kuruhuru,

this looks not so bad ;)
I've compared your build script with my settings and the only difference I see is that I have an additional entry in the layout before the zip.

Transformed to your script it looks like

default layout:

  plugin d0sl_plugin

 
zip d0sl-plugin-mps-2018-3-3.zip
     plugin d0sl_plugin

With this ant builds the plugin content before it is packaged to the zip. There might be other/better ways, but it works for me.

0

Please sign in to leave a comment.