Feel free to point me to sbt docs for my questions--I just haven't been able to find the appropriate pages by searching, but there's a lot of sbt info out there, and I imagine the answers already exist.
I'm trying to build a simple Swing application (the LinePainting demo with slight modifications). My sbt config file is:
package com.digitaldoodles.context
import sbt._
class SBTConfig(info: ProjectInfo) extends DefaultProject(info) {
val scalaToolsSnapshots = ScalaToolsSnapshots
val scalaSwing = "org.scala-lang" % "scala-swing" % "2.8.1"
val scalatest = "org.scalatest" % "scalatest" % "1.3-SNAPSHOT"
}
sbt picks up changes I make to the config file, but doesn't seem to be doing anything about the scalaSwing declaration. I'll confess that don't really understand what sbt does with declarations like 'val scalaSwing'; I haven't found any explanations of how sbt translates that into paths used in the compile or run phases of an application. Feel free to recommend reading. (My background is more of a tech writer than a software engineer, and is quite lacking in the intricacies of build tools and such.)
When I try to do a 'compile' on my code, I get:
[info] Source analysis: 1 new/modified, 0 indirectly invalidated, 0 removed.
[info] Compiling main sources...
[error] /Users/Ken/Documents/Programming/Scala/context/src/main/scala/Context.scala:6: value swing is not a member of package scala
[error] import scala.swing.event._
[error] /Users/Ken/Documents/Programming/Scala/context/src/main/scala/Context.scala:42: value paintComponent is not a member of AnyRef
[error] super.paintComponent(g)
which I'm interpreting as meaning that the dependency on scala-swing in the compile phase isn't being picked up.
I know Mark is doing a lot of work on documentation for sbt 0.9, and I'm really looking forward to that. Thanks for the help, everyone!
Ken McDonald