LowFieldTheory
LowFieldTheory

Reputation: 1773

Changing scala version of play from console

I should revert my project to scala 2.10.0, but it looks like I cannot from the console. I've tried to clean and rebuild with scalaVersion := "2.10.0" in the build.sbt, but it keeps using the 2.10.2. How can I do something like "play scala-version 2.10.0" ? (which doesn't seem to be correct) I know it uses the 2.10.2 because it is using scala-compiler and reflect 2.10.2

Upvotes: 0

Views: 140

Answers (1)

Jacek Laskowski
Jacek Laskowski

Reputation: 74679

jacek:~/sandbox/play-ground/xApp
$ play
[info] Loading global plugins from /Users/jacek/.sbt/0.13/plugins
[info] Updating {file:/Users/jacek/.sbt/0.13/plugins/}global-plugins...
[info] Resolving org.fusesource.jansi#jansi;1.4 ...
[info] Done updating.
[info] Loading project definition from /Users/jacek/sandbox/play-ground/xApp/project
[info] Set current project to xApp (in build file:/Users/jacek/sandbox/play-ground/xApp/)
       _
 _ __ | | __ _ _  _
| '_ \| |/ _' | || |
|  __/|_|\____|\__ /
|_|            |__/

play 2.2.2 built with Scala 2.10.3 (running Java 1.7.0_51), http://www.playframework.com

> Type "help play" or "license" for more information.
> Type "exit" or use Ctrl+D to leave this console.

[xApp] $ show scalaVersion
[info] 2.10.3
[xApp] $ set scalaVersion := "2.10.0"
[info] Defining *:scalaVersion
[info] The new value will be used by *:allDependencies, *:dependencyUpdatesData and 11 others.
[info]  Run `last` for details.
[info] Reapplying settings...
[info] Set current project to xApp (in build file:/Users/jacek/sandbox/play-ground/xApp/)
[xApp] $ show scalaVersion
[info] 2.10.0
[xApp] $ session save
[info] Reapplying settings...
[info] Set current project to xApp (in build file:/Users/jacek/sandbox/play-ground/xApp/)
[xApp] $ show scalaVersion
[info] 2.10.0
[xApp] $ about
[info] This is sbt 0.13.0
[info] The current project is {file:/Users/jacek/sandbox/play-ground/xApp/}xapp 1.0-SNAPSHOT
[info] The current project is built against Scala 2.10.0
[info] Available Plugins: com.typesafe.sbt.SbtGit, com.typesafe.sbt.SbtProguard, growl.GrowlingTests, org.sbtidea.SbtIdeaPlugin, sbtman.Plugin, np.Plugin, com.timushev.sbt.updates.UpdatesPlugin, play.Project, com.typesafe.sbteclipse.plugin.EclipsePlugin, com.typesafe.sbt.SbtNativePackager
[info] sbt, sbt plugins, and build definitions are using Scala 2.10.3

You should see the version in build.sbt in the project afterwards.

jacek:~/sandbox/play-ground/xApp
$ cat build.sbt
name := "xApp"

version := "1.0-SNAPSHOT"

libraryDependencies ++= Seq(
  jdbc,
  anorm,
  cache
)

scalaVersion := "2.10.0"

Upvotes: 2

Related Questions