0

I have a parent Maven project, which has two modules a main starting one and a lib. I am using the exec plugin in the parent project, and I would like to be able to fire up the already packaged main module like so:

java -jar <MAIN_MODULE_TARGET_DIR>/<MAIN_MODULE_TARGET_NAME>.jar

The problem is that I could not find appropriate properties anywhere. I have been looking for ${main.build.finalName} or ${modules.main.build.finalName}, but nothing like that exists. The only matching properties are related to the current project itself i.e. ${project.build.finalName}

What can I do to achieve this?

Preslav Rachev
  • 3,983
  • 6
  • 39
  • 63
  • Have you tried [this](http://stackoverflow.com/a/14490656/1858327) but in the modules' poms instead of the parent's? – Captain Man May 01 '15 at 18:22
  • Well, the reason is that one of the modules should actually work as a java agent for the other. Instead of letting the modules explicitly know about this, I'd like to encapsulate this knowledge only in the parent. – Preslav Rachev May 02 '15 at 10:41

0 Answers0