Skip to content

Commit

Permalink
Add source and javadoc JARs for Maven Central deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
kriegaex committed Feb 11, 2024
1 parent 46bc241 commit 338538a
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -325,15 +325,33 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>3.11.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>3.3.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.6.0</version>
<configuration>
<quiet>true</quiet>
<!-- Amend mojo-parent default config, avoiding errors concerning modules vs. unnamed module packages -->
<source>8</source>
<!-- Reproducible builds, https://maven.apache.org/guides/mini/guide-reproducible-builds.html -->
<notimestamp>true</notimestamp>
<!--
Avoid non-English javadoc generation. Due to https://bugs.openjdk.org/browse/JDK-8222793 reoccurring at
least in JDKs 19-21 and also being broken in some older JDKs, we cannot rely on just setting the locale
parameter, but also need the 'user.language' and 'user.country' parameters in 'additionalJOptions' as a
workaround.
-->
<locale>en</locale>
<additionalJOptions>
<additionalJOption>-J-Dfile.encoding=UTF-8</additionalJOption>
<additionalJOption>-J-Duser.language=en</additionalJOption>
<additionalJOption>-J-Duser.country=US</additionalJOption>
</additionalJOptions>
</configuration>
</plugin>
<plugin>
Expand Down Expand Up @@ -642,6 +660,33 @@
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<executions>
<execution>
<id>default-jar-no-fork</id>
<goals>
<goal>jar-no-fork</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<failOnError>false</failOnError>
</configuration>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
Expand Down

0 comments on commit 338538a

Please sign in to comment.