#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 <additionalJOptions /> 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 <additionalOptions /> (note the missing J) seems to pipe the attributes into the Javadoc tool in the order it would like to receive them.
This commit is contained in:
committed by
Mark Paluch
parent
6066b1ce57
commit
f4ce6eb09e
@@ -1264,6 +1264,7 @@
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
<configuration>
|
||||
<locale>en_US</locale>
|
||||
<breakiterator>true</breakiterator>
|
||||
<header>${project.name}</header>
|
||||
<source>${source.level}</source>
|
||||
@@ -1273,9 +1274,9 @@
|
||||
<stylesheetfile>${shared.resources}/javadoc/spring-javadoc.css</stylesheetfile>
|
||||
<!-- copies doc-files subdirectory which contains image resources -->
|
||||
<docfilessubdirs>true</docfilessubdirs>
|
||||
<additionalJOptions>
|
||||
<additionalJOption>-Xdoclint:none</additionalJOption>
|
||||
</additionalJOptions>
|
||||
<additionalOptions>
|
||||
<additionalOption>-Xdoclint:none</additionalOption>
|
||||
</additionalOptions>
|
||||
<sourcepath>target/generated-sources/delombok</sourcepath>
|
||||
<links>
|
||||
<link>https://docs.spring.io/spring/docs/5.0.x/javadoc-api/</link>
|
||||
|
||||
Reference in New Issue
Block a user