This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case class Foo(bar: Int) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Note: the system property `sbt.global.base` was introduced in 0.10.1 | |
## sbt-0.10.0 still uses the default global directory in ~/.sbt | |
gseitz@QBallz ~/.sbt % find . -name '*target*' -prune -o -print | |
. | |
./0.10.1 | |
./0.10.1/plugins | |
./0.10.1/plugins/build.sbt | |
./0.10.1/plugins/project |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// RetroLogger | |
// A handy sbt-0.10.x plugin that allows you to set the log level like in the old days (aka sbt-0.7.x) | |
// "set logLevel := Level.Debug" ====> "debug" | |
// | |
// + put this file in ~/.sbt/plugins/ | |
// + add "sbtPlugin := true" to ~/.sbt/plugins/build.sbt | |
import sbt._ | |
import Keys._ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sbt._ | |
import Keys._ | |
// source of the actual shell modification take from Daniel C. Sobral's gist: | |
// https://gist.github.com/996474 | |
// prompt looks like: | |
// $PROJECTNAME:$GITBRANCH> | |
object ShellPrompt extends Plugin { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sbt._ | |
import Keys._ | |
object MyBuild extends Build { | |
lazy val beforeDeploy = TaskKey[Unit]("before-deploy", "will be invoked before deploy") | |
val externalProcess = "echo $HOME" | |
override lazy val settings: Seq[Setting[_]] = Seq[Setting[_]]( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.specs2.mutable.Specification | |
import org.specs2.matcher.MatchResult | |
// protected[specs2] trait MatchResult[T] ... | |
class DummySpec extends Specification { | |
// Is MatchResult escaping its visibility scope here? | |
// vvvvvvvvvvv | |
def intSpec: MatchResult[Int] = 1 must be equalTo 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sbt._ | |
import Keys._ | |
import com.github.siasia.{WebPlugin=>WP} | |
object MyBuild extends Build { | |
val myTask = TaskKey[Unit]("my-task") | |
lazy val myProject = Project("webproject", file("."), settings =Defaults.defaultSettings ++ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package example | |
import org.specs2.mutable.Specification | |
import org.specs2.matcher.MatchResult | |
class DummySpec extends Specification { | |
def intSpec: MatchResult[Int] = 1 must be equalTo 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package test2 | |
import test.MyTrait | |
class MyClass extends MyTrait |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.awt.TrayIcon | |
import java.awt.SystemTray.{getSystemTray => tray} | |
import java.awt.Toolkit.{getDefaultToolkit => toolkit} | |
import java.net.URL | |
object Notification { | |
private lazy val scalaIcon = { | |
// of course we use the logo of our favorite language ;) | |
val img = toolkit.getImage(new URL("http://www.scala-lang.org/sites/default/files/favicon.gif")) | |
new TrayIcon(img) |