Skip to content

Commit

Permalink
[Build] Set Java Compiler's -release option instead of -source + -target
Browse files Browse the repository at this point in the history
Using the --release option instead --source plus --target is more
convenient (just one option) and more powerful (checks also that now
newer Java API is used even if the executing JDK is newer).
  • Loading branch information
iils-hwellmann committed Oct 25, 2024
1 parent 541b941 commit 212b6e6
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,7 @@
<maven.compiler.encoding>UTF-8</maven.compiler.encoding>

<!-- pin the source code compatibility to 11 for the sake of backward compatibility -->
<maven.compiler.source>11</maven.compiler.source>

<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.release>11</maven.compiler.release>

<!-- Enable java assertions during junit test runs. -->
<!-- The "enableAssertions" property is only available in the maven-surefire plugin. -->
Expand Down Expand Up @@ -414,7 +412,7 @@
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.5.0</version>
<configuration>
<source>8</source>
<source>${maven.compiler.release}</source>
<tags>
<!-- Let JavaDoc know about tags from Xtext -->
<tag>
Expand Down

0 comments on commit 212b6e6

Please sign in to comment.