Skip to content

Conversation

@pilardi
Copy link

@pilardi pilardi commented May 21, 2025

Whenever you have a multi-module project, you likely don't want to run the shell on every module of it but on a specific one. Typically in maven you select the project with the -pl flag.

This PR makes it so that the plugin skips the shell run if the selected project is not the one currently being built. IE:

mvn com.github.johnpoth:jshell-maven-plugin:1.5-SNAPSHOT:run -pl module1 -am

will run the shell only in module1 and skip any other modules. Before this change, the shell would have been executed for every module in the project.

Impl Note:
Unfortunately maven plugins jars, at least v3.x, are not modularized, by declaring the module exposes conflicting packages in the maven plugins namespace, maven-core clashes with maven-annotations plugins so I had to remove module definition until maven hierarchy is updated to java 9 standards.

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

Successfully merging this pull request may close these issues.

1 participant