initial commit
This commit is contained in:
106
build.sbt
Normal file
106
build.sbt
Normal file
@@ -0,0 +1,106 @@
|
||||
import sbt.Keys._
|
||||
|
||||
name := "redstream"
|
||||
|
||||
resolvers in Scope.GlobalScope += Resolver.sonatypeRepo("snapshots")
|
||||
|
||||
libraryDependencies += "com.lihaoyi" %%% "utest" % "0.3.0" % "test"
|
||||
|
||||
testFrameworks += new TestFramework("utest.runner.Framework")
|
||||
|
||||
|
||||
lazy val commonSettings = Seq{
|
||||
version := "1.0"
|
||||
scalaVersion := "2.11.8"
|
||||
}
|
||||
|
||||
lazy val root = project.in(file("."))
|
||||
.aggregate(apiJS, apiJVM)
|
||||
.settings(commonSettings:_*)
|
||||
|
||||
|
||||
lazy val IterateeVersion = "0.4.0-SNAPSHOT"
|
||||
lazy val CirceVersion = "0.4.0-RC1"
|
||||
lazy val MonixVersion = "2.0-M1"
|
||||
lazy val ShapelessVersion = "2.3.0"
|
||||
|
||||
lazy val api = crossProject
|
||||
.settings(commonSettings:_*)
|
||||
.settings(
|
||||
name := "api",
|
||||
initialCommands in console :=
|
||||
"""
|
||||
|import net.shimun.redstream._
|
||||
|import api._
|
||||
|import io.iteratee._
|
||||
|import scala.concurrent._
|
||||
|import monix.async._
|
||||
|implicit val ds = api.DataSource.Default
|
||||
|import ds._
|
||||
""".stripMargin.split("\n").mkString(";")
|
||||
).jvmSettings(
|
||||
libraryDependencies ++= Seq(
|
||||
"io.circe" %% "circe-parser" % CirceVersion,
|
||||
"io.circe" %% "circe-generic" % CirceVersion,
|
||||
"io.iteratee" %% "iteratee-core" % IterateeVersion,
|
||||
"io.monix" %% "monix-async" % MonixVersion,
|
||||
"com.chuusai" %% "shapeless" % ShapelessVersion
|
||||
)
|
||||
).jsSettings(
|
||||
libraryDependencies ++= Seq(
|
||||
"io.circe" %%% "circe-parser" % CirceVersion,
|
||||
"io.circe" %%% "circe-generic" % CirceVersion,
|
||||
"io.iteratee" %%% "iteratee-core" % IterateeVersion,
|
||||
"io.monix" %%% "monix-async" % MonixVersion,
|
||||
"com.chuusai" %%% "shapeless" % ShapelessVersion,
|
||||
"org.scala-js" %%% "scalajs-dom" % "0.8.0"
|
||||
)
|
||||
).enablePlugins(ScalaJSPlugin)
|
||||
|
||||
lazy val apiJS = api.js
|
||||
|
||||
lazy val apiJVM = api.jvm
|
||||
|
||||
lazy val client = project
|
||||
.settings(commonSettings:_*)
|
||||
.settings(
|
||||
libraryDependencies ++= Seq(
|
||||
"org.scala-js" %%% "scalajs-dom" % "0.8.0",
|
||||
"com.github.japgolly.scalajs-react" %%% "core" % "0.10.4",
|
||||
"com.github.japgolly.scalacss" %%% "ext-react" % "0.4.0",
|
||||
"com.chuusai" %%% "shapeless" % "2.2.5"
|
||||
),
|
||||
persistLauncher := true,
|
||||
jsDependencies += RuntimeDOM,
|
||||
jsDependencies ++= Seq(
|
||||
"org.webjars.bower" % "react" % "0.14.3"
|
||||
/ "react-with-addons.js"
|
||||
minified "react-with-addons.min.js"
|
||||
commonJSName "React",
|
||||
|
||||
"org.webjars.bower" % "react" % "0.14.3"
|
||||
/ "react-dom.js"
|
||||
minified "react-dom.min.js"
|
||||
dependsOn "react-with-addons.js"
|
||||
commonJSName "ReactDOM")
|
||||
)
|
||||
.dependsOn(apiJS)
|
||||
.dependsOn(`client-macros`)
|
||||
.enablePlugins(ScalaJSPlugin)
|
||||
|
||||
lazy val `client-macros` = project
|
||||
.settings(commonSettings:_*)
|
||||
.settings(
|
||||
libraryDependencies <+= scalaVersion("org.scala-lang" % "scala-compiler" % _)
|
||||
)
|
||||
.enablePlugins(ScalaJSPlugin)
|
||||
|
||||
skip in packageJSDependencies := false
|
||||
|
||||
|
||||
|
||||
//jsDependencies += "org.webjars" % "ractive" % "0.7.1" / "ractive.js" minified "ractive.min.js"
|
||||
|
||||
//which one ?
|
||||
|
||||
|
Reference in New Issue
Block a user