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

[MCOMPILER-550] make outputDirectory writable #202

Merged
merged 2 commits into from
Oct 23, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion src/main/java/org/apache/maven/plugin/compiler/CompilerMojo.java
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,17 @@ public class CompilerMojo extends AbstractCompilerMojo {

/**
* The directory for compiled classes.
* <p>
* This parameter should only be modified in special cases. One example is creating
* a multi-release jar with a lower bytecode level (i.e. setting it to
* {@code ${project.build.outputDirectory}/META-INF/versions/21} or similar) in an additional
* execution.
* <p>
* When the required bytecode level is available though an installed JDK or toolchain,
* it is recommended to use the {@code <release>} property
* in conjunction with the ${multiReleaseOutput} parameter instead.
*/
@Parameter(defaultValue = "${project.build.outputDirectory}", required = true, readonly = true)
@Parameter(defaultValue = "${project.build.outputDirectory}", required = true, readonly = false)
private File outputDirectory;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,13 @@ public class TestCompilerMojo extends AbstractCompilerMojo {

/**
* The directory where compiled test classes go.
* <p>
* This parameter should only be modified in special cases.
* See the {@link CompilerMojo#outputDirectory} for more information.
*
* @see CompilerMojo#outputDirectory
*/
@Parameter(defaultValue = "${project.build.testOutputDirectory}", required = true, readonly = true)
@Parameter(defaultValue = "${project.build.testOutputDirectory}", required = true, readonly = false)
private File outputDirectory;

/**
Expand Down