eclipse-lyo / lyo.designer

lyo.designer
Eclipse Public License 2.0
12 stars 10 forks source link

Deploy the Generated Metamodels and Generators to MavenCentral #158

Open sgarfinkel opened 4 years ago

sgarfinkel commented 4 years ago

It'd be very helpful if the generated metamodels, as well as the code generators, could be deployed to MavenCentral to facilitate standalone execution of the generators/standalone generation of the domain/toolchain models.

This would enable interesting enhancements, such as a CLI rather than GUI-only mode (as is currently implemented).

jadelkhoury commented 4 years ago

To me, there seems to be many requests in this issue. So let's break it down:

  1. You know that the standard OSLC models are defined under https://github.com/eclipse/lyo.domains . There you can find the model (to be re-used within your own if desired). But also the generated java classes, that can also be reused. See the Readme file on that repo to see how you can reuse without having to clode the project. The code is not under maven central, but we have our own maven repository.

  2. LyoDesigner can be triggered via command Line. See the two main functions in the Generate.java and GenerateSpecification.java files under https://github.com/eclipse/lyo.designer/tree/master/org.eclipse.lyo.oslc4j.codegenerator/src/org/eclipse/lyo/oslc4j/codegenerator/main

    • The challenge: How do we package this plugin so that it is available as a stand-alone exe. I believe the plugin was designed to be stand-alone. But I never really tested it.

But to start with, is this what you had in mind?

sgarfinkel commented 4 years ago

The meta models I’m referencing are these https://github.com/eclipse/lyo.designer/tree/master/org.eclipse.lyo.oslc4j.adaptormodel which could be used by others to directly generate Lyo inputs.

Which ties into the second part where those inputs could be used to run the generators in a standalone mode. In terms of the second part though I think we are in agreement :)

jadelkhoury commented 4 years ago

Ok got it. @berezovskyi I think this is now exactly the feature you talked about today, right?

With a quick google search, I could see some ideas on how to run an eclipse plugin from commandline, with headless eclipse. But it would be really nice if we can package/build/bundle the whole generator as a single standalone library.

danlz commented 1 year ago

Maybe you could provide a Maven plugin for code generation?

Jad-el-khoury commented 9 months ago

A maven plugin would be great. All contributions to the Lyo project are welcome.