Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Codegenerator] Version Support for Codegen Plugins #5368

Closed
juergen-albert opened this issue Sep 12, 2022 · 1 comment
Closed

[Codegenerator] Version Support for Codegen Plugins #5368

juergen-albert opened this issue Sep 12, 2022 · 1 comment
Assignees

Comments

@juergen-albert
Copy link
Contributor

In its current form, I can define a version in my -generate instruction. As far as I understand the code, this is only taken into account for generators, where a Main method is called.

if (pluginName.indexOf('.') >= 0) {
if (pluginName.startsWith("."))
pluginName = pluginName.substring(1);
VersionRange range = st.version()
.map(VersionRange::valueOf)
.orElse(null);
result = doGenerateMain(pluginName, range, st._attrs(), arguments, stdin, stdout, stderr);
} else {
result = doGeneratePlugin(pluginName, st._attrs(), arguments, stdin, stdout, stderr);
}

For generator plugins, it seems to use the first or last version that is found. In our EMF Codegenerator workspace we want to use baselining. The baseline repo naturally contains the previous version of the codegenerator developed in this workspace. When I set the baseline repo, it always uses the old generator and the tests for the new features fail subsequently.

Thus it would be great to have a possibility to define a version(range) requirement for all types of generators. From my perspective it would be sufficient to use the bundle version. More fine grained on the plugin level would also be fine.

@pkriens pkriens self-assigned this Sep 16, 2022
@pkriens
Copy link
Member

pkriens commented Oct 6, 2022

Should be implemented in #5388

@pkriens pkriens closed this as completed Oct 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants