m.dr (70) [Avatar] Offline
As I started on the book and setup Giter8 noticed it installed SBT 0.12.

Is there a way to allow setup of latest version of SBT - 0.13?
Or I can set up SBT 0.13 and will Giter8 use that instead of 0.12?

Also SBT is pulling down Scala 2.9 and 2.10 libraries. Why does it need 2.9? Is there a way to avoid using 2.9 altogether?

I have Scala 2.10 installed on my Ubuntu box and is there any way to use that installation directly rather than pull down its own?

I ask as I feel that I should have control of the environments being used. that was the reason I started with Scalatra, to be minimal and in control of my environment.

Hope this is a relevant question. Maybe I need to learn SBT more or ask the question on Giter8?

Thanks again for your help and much for the book.
rossabaker (9) [Avatar] Offline
Re: Using Giter8 / SBT
The Scala 2.9 dependencies are a result of sbt-0.12 being built on Scala 2.9.2. sbt needs to pull a Scala to bootstrap itself, and then 2.10 is pulled to power your app.

The g8 template specifies which version of sbt is used. That is set in project/build.properties of the materialized project, and can be changed. However, the scalatra-sbt plugin specified by the project is not yet published for sbt-0.13. I've opened issues so we can get that addressed, and upgrade the g8 template's default.


In the meantime, the sbt-0.12 from the project will let you use Scala 2.10, and require only minimal changes to upgrade your project to sbt-0.13.

rossabaker (9) [Avatar] Offline
Re: Using Giter8 / SBT
Upgrades are complete. New projects will be generated with sbt-0.13 as the default.

To upgrade your existing app, in project/build.properties:

And in project/plugins.sbt:
addSbtPlugin("org.scalatra.sbt" % "scalatra-sbt" % "0.3.2")
m.dr (70) [Avatar] Offline
Re: Using Giter8 / SBT
Thanks Ross. WIll look forward to trying them out shortly. Will update on results.