Skip to content

Commit

Permalink
non#25: Port to Scala.js
Browse files Browse the repository at this point in the history
  • Loading branch information
oyvindberg committed Feb 14, 2018
1 parent 3b8aacc commit 978b4f2
Show file tree
Hide file tree
Showing 10 changed files with 17 additions and 5 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,5 @@ TAGS
*~
.#*
.lib
.idea/
target/
17 changes: 12 additions & 5 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import ReleaseTransformations._

// shadow sbt-scalajs' crossProject and CrossType until Scala.js 1.0.0 is released
import sbtcrossproject.{crossProject, CrossType}

lazy val scalac: Seq[String] = Seq(
"-deprecation", // Emit warning and location for usages of deprecated APIs.
"-encoding", "utf-8", // Specify character encoding used by source files.
Expand Down Expand Up @@ -69,9 +72,9 @@ lazy val deboxSettings = Seq(

resolvers += Resolver.sonatypeRepo("releases"),
libraryDependencies ++= Seq(
"org.typelevel" %% "spire" % "0.14.1",
"org.scalatest" %% "scalatest" % "3.0.4" % "test",
"org.scalacheck" %% "scalacheck" % "1.13.5" % "test"
"org.typelevel" %%% "spire" % "0.14.1",
"org.scalatest" %%% "scalatest" % "3.0.4" % "test",
"org.scalacheck" %%% "scalacheck" % "1.13.5" % "test"
),


Expand Down Expand Up @@ -139,12 +142,16 @@ lazy val noPublishSettings = Seq(
publishArtifact := false
)

lazy val core = project
lazy val core = crossProject(JSPlatform, JVMPlatform)
.in(file("."))
.settings(moduleName := "debox")
.settings(deboxSettings)

lazy val benchmark = project.dependsOn(core)
lazy val coreJvm = core.jvm
lazy val coreJs = core.js

lazy val benchmark = project
.dependsOn(coreJvm)
.in(file("benchmark"))
.settings(moduleName := "debox-benchmark")
.settings(deboxSettings)
Expand Down
3 changes: 3 additions & 0 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@ addSbtPlugin("com.jsuereth" % "sbt-pgp" % "1.1.0")
addSbtPlugin("com.github.gseitz" % "sbt-release" % "1.0.7")
addSbtPlugin("org.xerial.sbt" % "sbt-sonatype" % "2.0")
addSbtPlugin("pl.project13.scala" % "sbt-jmh" % "0.3.2")
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "0.6.22")
addSbtPlugin("org.portable-scala" % "sbt-crossproject" % "0.3.1") // (1)
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "0.3.1") // (2)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 978b4f2

Please sign in to comment.