-
Notifications
You must be signed in to change notification settings - Fork 100
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
Module path can't be defined #335
Comments
Not sure if it is possible, but I would like the possibility to define a specific execution ID in a submodule and then target that from the command line: <plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<executions>
<execution>
<id>my-target</id>
<goals>
<goal>java</goal>
</goals>
<configuration>
<mainClass>...</mainClass>
</configuration>
</execution>
</executions>
</plugin>
Currently
Even when I define default <plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<executions>
<execution>
<id>my-target</id>
<goals>
<goal>java</goal>
</goals>
<configuration>
<skip>true</skip>
</configuration>
</execution>
</executions>
</plugin> it fails for not having <properties>
<exec.mainClass />
</properties> This could result in a suboptimal experience with other See also:
|
mvn package -DskipTests exec:java@demo mvn package -DskipTests exec:java@demo -Dexec.args=write_obj See also: - Plugin Goal Invocation from Command Line <https://maven.apache.org/docs/3.3.1/release-notes.html#plugin-goal-invocation-from-command-line> - mojohaus/exec-maven-plugin#335
Hello!
The problem is in module path. When plugin run main class, which is in module it defines the root path. Therefore, I can't use files in module because the path there isn't correct.
`
Main pom.xml
4.0.0
----------------------------- module pom.xml -----------
`
RunTestId
org.example
1.0-SNAPSHOT
4.0.0
Actual result:
The path file in module is C:/RunTests/src/main/resources/text.txt
Expected result:
The path file in module is C:/RunTests/ModuleOne/src/main/resources/text.txt
The text was updated successfully, but these errors were encountered: