Skip to content

Commit

Permalink
Merge pull request #142 from larsrh/topic/2.12
Browse files Browse the repository at this point in the history
Scala 2.12.0-RC2
  • Loading branch information
lihaoyi authored Nov 1, 2016
2 parents d6a2704 + 5a3ee58 commit 42f4aee
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 25 deletions.
15 changes: 11 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
language: scala
script:
- sbt ++2.11.5 readme/run
- sbt ++$TRAVIS_SCALA_VERSION scalatagsJVM/test scalatagsJS/test
- sbt ++2.11.8 readme/run
- sbt ++$TRAVIS_SCALA_VERSION scalatagsJVM/test scalatagsJS/test
scala:
- 2.10.4
- 2.11.4
- 2.10.6
- 2.11.8
- 2.12.0
jdk:
- openjdk7
- oraclejdk8
matrix:
exclude:
- scala: 2.12.0
jdk: openjdk7
sudo: false
39 changes: 22 additions & 17 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
scalaVersion := "2.11.8"

crossScalaVersions := Seq("2.11.8", "2.10.4")
crossScalaVersions := Seq("2.11.8", "2.10.6", "2.12.0")

resolvers in ThisBuild += Resolver.sonatypeRepo("releases")

lazy val scalatags = crossProject
.settings(
Expand All @@ -10,21 +12,26 @@ lazy val scalatags = crossProject

autoCompilerPlugins := true,
libraryDependencies ++= Seq(
"com.lihaoyi" %% "acyclic" % "0.1.2" % "provided",
"com.lihaoyi" %%% "utest" % "0.3.1" % "test",
"com.lihaoyi" %%% "sourcecode" % "0.1.1",
"com.lihaoyi" %% "acyclic" % "0.1.5" % "provided",
"com.lihaoyi" %%% "utest" % "0.4.4" % "test",
"com.lihaoyi" %%% "sourcecode" % "0.1.3",
"org.scala-lang" % "scala-reflect" % scalaVersion.value % "provided"
) ++ (
if (scalaVersion.value startsWith "2.11.") Nil
else Seq(
"org.scalamacros" %% s"quasiquotes" % "2.0.0" % "provided",
compilerPlugin("org.scalamacros" % s"paradise" % "2.0.0" cross CrossVersion.full)
)
if (scalaVersion.value startsWith "2.10.")
Seq(
"org.scalamacros" %% s"quasiquotes" % "2.1.0" % "provided",
compilerPlugin("org.scalamacros" % s"paradise" % "2.1.0" cross CrossVersion.full)
)
else Nil
),
addCompilerPlugin("com.lihaoyi" %% "acyclic" % "0.1.2"),
unmanagedSourceDirectories in Compile ++= {
if (scalaVersion.value startsWith "2.12.") Seq(baseDirectory.value / ".."/"shared"/"src"/ "main" / "scala-2.11")
else Seq()
},
addCompilerPlugin("com.lihaoyi" %% "acyclic" % "0.1.5"),
libraryDependencies ++= (
if (scalaVersion.value.startsWith("2.10")) Nil
else Seq("org.scala-lang.modules" %% "scala-xml" % "1.0.1" % "test")
else Seq("org.scala-lang.modules" %% "scala-xml" % "1.0.5" % "test")
),
testFrameworks += new TestFramework("utest.runner.Framework"),
// Sonatype
Expand Down Expand Up @@ -53,13 +60,12 @@ lazy val scalatags = crossProject
)
.jvmSettings()
.jsSettings(
scalaJSUseRhino in Global := false,
libraryDependencies ++= Seq(
"org.scala-js" %%% "scalajs-dom" % "0.9.1"
),
resolvers += Resolver.sonatypeRepo("releases"),
scalaJSStage in Test := FullOptStage,
requiresDOM := true,
jsEnv := PhantomJSEnv().value,
scalacOptions ++= (if (isSnapshot.value) Seq.empty else Seq({
val a = baseDirectory.value.toURI.toString.replaceFirst("[^/]+/?$", "")
val g = "https://raw.githubusercontent.com/lihaoyi/scalatags"
Expand All @@ -77,8 +83,7 @@ lazy val example = project.in(file("example"))
.dependsOn(scalatagsJS)
.enablePlugins(ScalaJSPlugin)
.settings(
crossScalaVersions := Seq("2.11.4", "2.10.4"),
scalaVersion := "2.11.4",
scalaVersion := "2.11.8",
scalacOptions ++= Seq(
"-deprecation", // warning and location for usages of deprecated APIs
"-feature", // warning and location for usages of features that should be imported explicitly
Expand All @@ -103,11 +108,11 @@ lazy val readme = scalatex.ScalatexReadme(
(unmanagedSources in Compile) += baseDirectory.value/".."/"project"/"Constants.scala",
(resources in Compile) += (fullOptJS in (example, Compile)).value.data,
(resources in Compile) += (doc in (scalatagsJS, Compile)).value,
(run in Compile) <<= (run in Compile).dependsOn(Def.task{
(run in Compile) := (run in Compile).dependsOn(Def.task{
sbt.IO.copyDirectory(
(doc in (scalatagsJS, Compile)).value,
(target in Compile).value/"scalatex"/"api",
overwrite = true
)
})
}).evaluated
)
2 changes: 1 addition & 1 deletion project/Constants.scala
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package scalatags
object Constants{
val version = "0.6.1"
val version = "0.6.2"
}
2 changes: 1 addition & 1 deletion project/build.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
sbt.version=0.13.8
sbt.version=0.13.13
2 changes: 1 addition & 1 deletion project/build.sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "0.6.8")
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "0.6.13")

addSbtPlugin("com.typesafe.sbt" % "sbt-twirl" % "1.1.1")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package scalatags
package generic

import acyclic.file
import utest.framework.TestSuite
import utest._

import TestUtil._
Expand Down

0 comments on commit 42f4aee

Please sign in to comment.