Skip to content

switching scala version clobbers settings for `scalaVersion in update` #211

Closed
harrah opened this Issue Jan 5, 2013 · 1 comment

1 participant

@harrah
Owner
harrah commented Jan 5, 2013

I have a setting to choose a scalaVersion in update depending on the current scalaVersion.

    scalaVersion in update ~= {
      case "2.10.0-SNAPSHOT" => "2.9.0-1"
      case "2.9.1" => "2.9.0-1"
      case x => x
    }

Unfortunately this setting doesn't work after switching versions or cross building.

>   ~/code/scalaz sbt 
Detected sbt version 0.11.0
Starting sbt: invoke with -help for other options
[info] Loading global plugins from /Users/jason/.sbt/plugins
[info] Loading project definition from /Users/jason/code/scalaz/project
[info] Set current project to scalaz (in build file:/Users/jason/code/scalaz/)
> scalaz-core/scala-version
[info] 2.9.1
> scalaz-core/scala-version(for update)
[info] 2.9.0-1
> ++ 2.9.1                             
Setting version to 2.9.1
[info] Set current project to scalaz (in build file:/Users/jason/code/scalaz/)
> scalaz-core/scala-version(for update)
[info] 2.9.1

Looks like it is being excluded in Cross.scala:

  def crossExclude(s: Setting[_]): Boolean =
    s.key.key == scalaVersion.key || s.key.key == scalaHome.key
@harrah
Owner
harrah commented Jan 5, 2013

IMPORTANT This project has moved to https://github.com/sbt/sbt. This issue still exists to avoid dead links, but GitHub limitations prevent the original issue from being correctly preserved here. Please see sbt/sbt#211 for the full issue and to comment.

@harrah harrah closed this Jan 5, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.