> -----Original Message-----
> From: Manfred Moser [mailto:manf...@mosabuam.com] 
> Sent: Thursday, June 18, 2015 12:21 AM
> To: dev@maven.apache.org
> Subject: Re: Default Maven Compiler Version
> 
> Yes... a corporate or some other higher level pom is 

I think some detail was missed in the OP's question.

It is not that he always wants version X. It is he wants the default to be
the version in the path for each system.

In other words: On system A it should be java version A on system B it
should be java version B, etc.

Maybe start with this idea:

<properties>
  <maven.compiler.source>${java.version}</maven.compiler.source>
  <maven.compiler.target>${java.version}</maven.compiler.target>
</properties>

Now I know that ${java.version} is likley to have some cruft in it, but
someone better than I can come up with a way to strip out the 1.x from the
java.version.


> typically how you configure this across lots of projects. But 
> even if you dont ... its two lines of config on the compiler plugin.
> 
> Manfred
> 
> Sander Verhagen wrote on 17.06.2015 15:16:
> 
> > I wonder if this would be a good candidate for a corporate POM that 
> > deals with this kind of configuration?
> > 
> > 
> > 
> > Sander Verhagen
> > [  san...@sanderverhagen.net  ]
> > 
> > NOTICE: my e-mail address has changed. You may still e-mail me at 
> > verha...@sander.com but you will see me using 
> > san...@sanderverhagen.net from now on. Feel free to update 
> your address book.
> > 
> >> -----Original Message-----
> >> From: Mangold, Kevin C. [mailto:kevin.mang...@nist.gov]
> >> Sent: Wednesday, June 17, 2015 12:55
> >> To: dev@maven.apache.org
> >> Subject: Default Maven Compiler Version
> >> 
> >> Why does the maven compiler plugin STILL target 1.5 by default and 
> >> not the JDK's current version? This seems completely backwards. We 
> >> use CI tools to test against different JDK versions and 
> architectures 
> >> and it is a massive pain to implement all these 
> workarounds to have 
> >> the compiler target each JDK's respective version.


--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-                                                               -
- Jason Pyeron                      PD Inc. http://www.pdinc.us -
- Principal Consultant              10 West 24th Street #100    -
- +1 (443) 269-1555 x333            Baltimore, Maryland 21218   -
-                                                               -
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org

Reply via email to