[ 
https://issues.apache.org/jira/browse/MENFORCER-288?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Konrad Windszus updated MENFORCER-288:
--------------------------------------
    Description: 
Although with MENFORCER-274 it is now possible to specify 

{code}
                <requireJavaVersion>
                  <version>9</version>
                </requireJavaVersion>
{code}

it is still not possible to refer to older java versions without the leadering 
{{1}}.
So e.g. this one does not work

{code}
                <requireJavaVersion>
                  <version>6</version>
                </requireJavaVersion>
{code}
This would be very handy as with JDK 9 you specify e.g. release only without 
the preceeding {{1}} (compare with 
https://docs.oracle.com/javase/9/tools/javac.htm#GUID-AEEC9F07-CB49-4E96-8BC7-BCC2C7F725C9__GUID-D343F6B4-3FDD-43A8-AD24-43DD70214471).
 As it is very common to reuse the same Maven property value for enforcing the 
minimum java version as well as for specifying the release of the maven 
compiler plugin it would be nice, if both support the same version range.

To still be backwards compatible I would suggest that in case of 6,7,8 given as 
a value, the {{1.}} is implicitly prepended by the {{maven-enforcer-plugin}}.

  was:
Although with MENFORCER-247 it is now possible to specify 

{code}
                <requireJavaVersion>
                  <version>9</version>
                </requireJavaVersion>
{code}

it is still not possible to refer to older java versions without the leadering 
{{1}}.
So e.g. this one does not work

{code}
                <requireJavaVersion>
                  <version>6</version>
                </requireJavaVersion>
{code}
This would be very handy as with JDK 9 you specify e.g. release only without 
the preceeding {{1}} (compare with 
https://docs.oracle.com/javase/9/tools/javac.htm#GUID-AEEC9F07-CB49-4E96-8BC7-BCC2C7F725C9__GUID-D343F6B4-3FDD-43A8-AD24-43DD70214471).
 As it is very common to reuse the same Maven property value for enforcing the 
minimum java version as well as for specifying the release of the maven 
compiler plugin it would be nice, if both support the same version range.

To still be backwards compatible I would suggest that in case of 6,7,8 given as 
a value, the {{1.}} is implicitly prepended by the {{maven-enforcer-plugin}}.


> RequireJavaVersion: Support new Java 9 versioning schema even for older Java 
> versions
> -------------------------------------------------------------------------------------
>
>                 Key: MENFORCER-288
>                 URL: https://issues.apache.org/jira/browse/MENFORCER-288
>             Project: Maven Enforcer Plugin
>          Issue Type: Improvement
>          Components: Standard Rules
>    Affects Versions: 3.0.0-M1
>            Reporter: Konrad Windszus
>
> Although with MENFORCER-274 it is now possible to specify 
> {code}
>                 <requireJavaVersion>
>                   <version>9</version>
>                 </requireJavaVersion>
> {code}
> it is still not possible to refer to older java versions without the 
> leadering {{1}}.
> So e.g. this one does not work
> {code}
>                 <requireJavaVersion>
>                   <version>6</version>
>                 </requireJavaVersion>
> {code}
> This would be very handy as with JDK 9 you specify e.g. release only without 
> the preceeding {{1}} (compare with 
> https://docs.oracle.com/javase/9/tools/javac.htm#GUID-AEEC9F07-CB49-4E96-8BC7-BCC2C7F725C9__GUID-D343F6B4-3FDD-43A8-AD24-43DD70214471).
>  As it is very common to reuse the same Maven property value for enforcing 
> the minimum java version as well as for specifying the release of the maven 
> compiler plugin it would be nice, if both support the same version range.
> To still be backwards compatible I would suggest that in case of 6,7,8 given 
> as a value, the {{1.}} is implicitly prepended by the 
> {{maven-enforcer-plugin}}.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to