Skip to content

Instantly share code, notes, and snippets.

View enijns's full-sized avatar

Egon Nijns enijns

  • Leuven
View GitHub Profile
@enijns
enijns / gist:5848692
Created June 24, 2013 08:57
slightly modified ReplyingActor (inspiration: http://www.warski.org/blog/2013/05/typed-ask-for-akka/)
trait ReplyingActor extends Actor {
final def receive = {
case m: Replyable[_] if receiveReplyable.isDefinedAt(m) => {
try {
sender ! receiveReplyable(m)
} catch {
case e: Exception => sender ! Failure(e)
}
}
case x => receiveOther(x)
@enijns
enijns / gist:5820924
Created June 20, 2013 07:44
multi-module sbt build, for which sbt-assembly doesn't seem to include the classfiles of the library project (in this case "wintermute-rules")
import sbt._
import Keys._
import sbtassembly.Plugin._
import AssemblyKeys._
import scala.Some
object WintermuteBuild extends Build {
lazy val root = Project(id = "wintermute", base = file(".")) aggregate(rules, app)
lazy val rules = Project(id = "wintermute-rules", base = file("wintermute-rules"))