sbt

How do I set a system property for my project in sbt?

I'm sure I'm missing something really simple... I want to set the system property java.awt.headless to true for my sbt project. Reading the page on properties I think that I need to use system or systemOptional. In my project file I've tried things like: lazy val javaAwtHeadless = system[Boolean]("java.awt.headless") Setting it as a u...

sbt: restarting a process on a code change

Using the ~run command, the simple build tool will re-run an executable target for me whenever a source file changes. This is nice, but if the target is a long-running server process, sbt is suspended until the child terminates, so source changes have no effect. I'd like to have sbt monitor and recompile my sources even while the tar...

Configure SBT's Ivy cache directory, per-user or system-wide

I am using SBT as my build tool for building a Scala project. My problem is, I can't let SBT download its dependencies to my user home directory. Therefore I am looking for a per-user or even better a system-wide setting to tell SBT to put the Ivy cache directory somewhere else. With maven there is the per-user settings.xml that can be...

Simple-Build-Tool Error highligtning in JEdit

Hello All I currently experimenting with different lightweight texteditors for Scala development. JEdit seems to enable the user to make many tweaks. However im currently having a problem with its error and warning highlightning, via the Console plugin. It marks some lines as errors without actually being it. Thats why I wanted to ...

How do I sign my ProGuard'ed Scala stand-alone JARs?

I've built a (command-line) application in Scala that I want to distribute as a standalone JAR. I'm building it with sbt: import sbt._ class Project(info: ProjectInfo) extends DefaultProject(info) with ProguardProject { override def parallelExecution = true override def mainClass: Option[String] = // whatever override def ...

Modifying watchpaths

SBT has triggered execution so if I execute a command like ~test It executes all test cases and then waits for source changes. I want to extend this behavior to get triggered execution whenever input files are changed. All input files exist in a single folder. To achieve this I created a scala file in project/buildfolder: import sbt....

"is not a member of package" error when importing package in Scala with SBT

(Relative beginner here, please be gentle...) I've got a Scala program that I can build with sbt. I can (from within sbt) run compile and test-compile with no errors. I've defined a package by putting package com.mycompany.mypackagename at the top of several .scala files. When I do console to get a Scala REPL, this happens: scala> impo...

Scala: Defining test cases based on folder

I have to test a program which takes one input file. I have put all the input files inside a folder and now I want to use SBT and ScalaTest to have following features: TestAll : Invoke the program with one input file at a time for all files Test one: Invoke the program with one input file provided as argument to test command from sbt c...

Circumflex and sbt

Has anyone successfully used Circumflex ORM from an sbt project? How can I specify my Circumflex properties, such as 'orm.connection.driver'? A properties.cx file is not picked up as my runtime classpath apparently contains only sbt-launch-0.7.3.jar. ...

Environment for java + scala + lift project in eclipse without maven

I'm trying to understand what's the best way to setup a project that is a mix of java and scala and that will use lift. Lift is intended to run embedded by jetty in another application. I'm comfortable to work in Eclipse and also used to how it works with ant as build tool. I'm a relatively newbie in both scala and lift and get confused...

Which CI server works with SBT?

I'm considering using SBT for a new scala project, but I'm not sure which CI server - hudson / cruise / whatever has support for it. Any ideas? I know SBT is a little Maven like, but I don't think it can work as a drop in replacement for Maven in the eyes of a CI server. ...

Sbt and the Fast Scala Compiler?

Does sbt make use of fsc? For test purposes I am compiling a 500-line program on a fairly slow Ubuntu machine (Atom N270). Three successive compile times were 77s, 66s, and 66s. I then compiled the file with fsc from the command line. Now my times were 80s, 25s, 18s. Better! That implies to me sbt is not using fsc. Am I right? If...

How do I get color coded console output from SBT on Windows?

I'm using SBT (Simple Build Tool) to build my Scala projects on Windows. I've seen that one of my friends, that runs OSX, gets color coded output in his terminal windows when running SBT, but mine is just the same color everywhere. Is there any way to enable this for Windows? ...

Scala SBT: AssertionError on build

I am using SBT (0.7.4) with Scala(2.7.7) to build my Scala project and sometimes I get following error when building the project. So far the only remedy seems to retry it or do a clean on the SBT shell which adds delay in build process. No definite pattern of occurrence of the error has emerged but it happens quite a lot when I am using...

How to configure SBT to use Scala 2.8?

I have Scala 2.8.0 installed and don't wish to use Scala 2.7. Whenever I try to use SBT, it begins downloading Scala 2.7.7. Even if I call it in a directory with a Scala 2.8 project. How to avoid this behaviour? There is no man page for SBT, neither I could find SBT configuration files in /etc or ~/. ...

Improve sbt doc generation

When I run sbt doc, it results in a nice but nonetheless pretty basic documentation. Is it possible to a) include the source files for the class definition and b) inherit the docstrings for inherited members? What do I need to add to my project definition? (It’s a Lift project, so most important would be to have the inherited Lift d...

How to force interpreter show complete stack trace?

Is there any way to force Scala interpreter (started through SBT) to print complete stack trace. By default, less than 10 lines are displayed: scala> new CacheMonitoringClient javax.management.InstanceNotFoundException: com.bea:Name=DomainRuntimeService,Type=weblogic.management.beanservers.domainrun time.DomainRuntimeServiceMBean ...

how do I get sbt to use a local maven proxy repository (Nexus)?

Hello, I've got an sbt (Scala) project that currently pulls artifacts from the web. We'd like to move towards a corporate-standardized Nexus repository that would cache artifacts. From the Nexus documentation, I understand how to do that for Maven projects. But sbt obviously uses a different approach. (I understand Ivy is involved someho...

GWT plugin for SBT / Using the Maven Plugin

Does anyone know of a GWT plugin for SBT? I can't seem to find one anywhere. If there isn't one, does anyone know how to use maven plugins from SBT for some tasks? I know this is possible, but can't figure out how. Can I just fit in the maven GWT plugin and use it? ...

How to add Jar libraries to an IntelliJ Idea SBT Scala project?

I've created an IntelliJ Idea SBT Scala project like Heiko Seeberger's article describes. I'd like to add a Jar library (joda-time) to use in this project. How to do this? Simply putting them into project's /lib does not help. If I right-click "External libraries" in Idea's project tree, "New >" is greyed. ...