From 73c97dc3ca223d29c6e7f0b42ef3baf37f28c8f5 Mon Sep 17 00:00:00 2001 From: Oliver Drotbohm Date: Mon, 6 Apr 2020 18:38:51 +0200 Subject: [PATCH] #1048 - Explicitly set Javadoc locale to English. Not setting the Javadoc's locale explicitly has cause the release building machine's local to end up as lang attribute in the HTML tag. Most releases build by folks in Germany, the "de" value causes browsers to suggest to translate the page content from German into the user's browser language in case that's not German in the first place. We now explicitly set the value to en_US, as we know the content is English anyway. Getting this fixed has been a bit of a ride as it takes a special way of convincing the Javadoc tool actually receive the locale attribute. For whatever reason, the locale attribute needs to be the first attribute piped to the Javadoc tool (yeah, exactly^^), which is at odds with our usage of the usage to disable Javadoc linting. The options always appear *before* any other attributes handed to the Javadoc tool and thus caused the build to fail with: javadoc: error - option -locale must be first on the command line. Switching to rather use (note the missing J) seems to pipe the attributes into the Javadoc tool in the order it would like to receive them. --- parent/pom.xml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/parent/pom.xml b/parent/pom.xml index 8f43c73c..147a471b 100644 --- a/parent/pom.xml +++ b/parent/pom.xml @@ -1226,6 +1226,7 @@ org.apache.maven.plugins maven-javadoc-plugin + en_US true
${project.name}
${source.level} @@ -1235,9 +1236,9 @@ ${shared.resources}/javadoc/spring-javadoc.css true - - -Xdoclint:none - + + -Xdoclint:none + target/generated-sources/delombok https://docs.spring.io/spring/docs/5.0.x/javadoc-api/