Question Details

No question body available.

Tags

java maven javadoc maven-javadoc-plugin

Answers (1)

January 13, 2026 Score: 0 Rep: 133 Quality: Low Completeness: 80%

I have found a workaround. It's not really a solution, but it avoids the problem.

  • Delete the 'docs' directory during the clean phase.
  • Generate the Javadoc the default way.
  • Copy the Javadoc from the default output directory into the 'docs' directory during the package phase.

...

org.apache.maven.plugins maven-clean-plugin 3.5.0

${basedir}/docs

true

org.apache.maven.plugins maven-javadoc-plugin 3.12.0

javadoc

jar

org.apache.maven.plugins maven-resources-plugin 2.6

copy-resources package

copy-resources

${basedir}/docs

target/reports/apidocs

If nobody answers, I'll eventually mark this as correct, but I'd still prefer a way to solve the actual problem.