This page is no longer maintained — Please continue to the home page at www.scala-lang.org

Fwd: Enforcing Scala version with Maven

No replies
hseeberger
Joined: 2008-12-27,
User offline. Last seen 1 year 25 weeks ago.
I fixed it in ScalaMojoSupport.checkArtifactForScalaVersion().
Even before the fix I could not build successfully (see below). Hence I had to remove the maven-invoker-plugin from the POM. Then I could successfully test my fix with ScalaModules.
I pushed the fix as a new branch wip-scala-versions. If you merge it, please take care of my temporary change in the POM.
The build error:
[ERROR] The following builds failed: [ERROR] *  testLotsofJavaFiles/pom.xml[ERROR] *  testLotsofJavaFilesNoFork/pom.xml[ERROR] *  vscaladocOnMultiModules/pom.xml[INFO] ---------------------------------------[INFO] ------------------------------------------------------------------------ [ERROR] BUILD FAILURE[INFO] ------------------------------------------------------------------------[INFO] : org.apache.maven.plugin.invoker.InvokerMojo@cbb3fa3 builds failed.
CheersHeiko

2009/6/10 David Bernard <david.bernard.31@gmail.com>
Did, I forgot to notify you.

On Wed, Jun 10, 2009 at 11:33, Josh Suereth <joshua.suereth@gmail.com> wrote:
Np! 
DavidB, want your ok before adding Heiko as a committee

Sent from my iPhone
On Jun 10, 2009, at 5:06 AM, Heiko Seeberger <heiko.seeberger@googlemail.com> wrote:

Josh,
The parameter will *not* make the build fail but only log with a leading "error" instead of a leading "warning". The Mojo should additionally throw an Exception. I did this locally and it worked. If you give me access to the repo I will patch it.
Heiko

2009/6/10 Josh Suereth <joshua.suereth@gmail.comjoshua.suereth@gmail.com>
Yes, there is a configuration parameter to do this.  Unfortunately, a lot of libraries have scala-library listed as a "provided" dependency, which does not get enforced.
I believe Heiko already sent the configuration parameter you can use.

Sent from my iPhone
On Jun 9, 2009, at 1:50 PM, David Pollak <feeder.of.the.bears@gmail.comfeeder.of.the.bears@gmail.com> wrote:

Folks,
Is there any way we can use Maven to enforce Scala versions such that libraries compiled with a certain version of Scala can only be used with the same version of Scala?
Thanks,
David

--
Lift, the simply functional web framework http://liftweb.net
Beginning Scala http://www.apress.com/book/view/1430219890
Follow me: http://twitter.com/dpp
Git some: http://github.com/dpp



--
My blog: heikoseeberger.name
Follow me: twitter.com/hseeberger
OSGi on Scala: www.scalamodules.org
Lift, the simply functional web framework: liftweb.net




--
My blog: heikoseeberger.name
Follow me: twitter.com/hseeberger
OSGi on Scala: www.scalamodules.org
Lift, the simply functional web framework: liftweb.net



--
My blog: heikoseeberger.name
Follow me: twitter.com/hseeberger
OSGi on Scala: www.scalamodules.org
Lift, the simply functional web framework: liftweb.net

Copyright © 2012 École Polytechnique Fédérale de Lausanne (EPFL), Lausanne, Switzerland