-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This: - Updates to SBT v1.2.8 - Uses coursier for SBT plugins - Migrates away from tut and to mdoc - Uses scala v2.11.12 and v2.12.8 - Updates monocle to v1.5.0 - Updates scalaz to v7.2.27 - Updates slamdata-predef to v0.0.7 - Updates sbt-slamdata to v2.4.1 - Drops support for openjdk7 in favor of openjdk8 since SBT v1 requires Scala 2.12 and thus JDK8 Question: do you still care about supporting 2.11?
- Loading branch information
Showing
89 changed files
with
342 additions
and
289 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,33 @@ | ||
import org.scalajs.sbtplugin.ScalaJSCrossVersion | ||
import scoverage._ | ||
import sbt._ | ||
import Keys._ | ||
import slamdata.SbtSlamData.transferPublishAndTagResources | ||
import sbt._, Keys._ | ||
import sbtcrossproject.CrossPlugin.autoImport.crossProject | ||
|
||
lazy val monocleVersion = "1.4.0" | ||
lazy val scalazVersion = "7.2.15" | ||
lazy val scala2_12 = "2.12.8" | ||
lazy val scala2_11 = "2.11.12" | ||
|
||
lazy val monocleVersion = "1.5.0" | ||
lazy val scalazVersion = "7.2.27" | ||
|
||
lazy val supportedScalaVersions = List(scala2_12, scala2_11) | ||
|
||
ThisBuild / scalaVersion := scala2_12 | ||
|
||
ThisBuild / crossScalaVersions := supportedScalaVersions | ||
|
||
lazy val standardSettings = commonBuildSettings ++ Seq( | ||
logBuffered in Compile := false, | ||
logBuffered in Test := false, | ||
Compile / logBuffered := false, | ||
Test / logBuffered := false, | ||
updateOptions := updateOptions.value.withCachedResolution(true), | ||
exportJars := true, | ||
organization := "com.slamdata", | ||
ScoverageKeys.coverageHighlighting := true, | ||
scalacOptions in (Compile, doc) ++= Seq("-groups", "-implicits"), | ||
wartremoverWarnings in (Compile, compile) --= Seq( | ||
Wart.PublicInference, // TODO: enable incrementally — currently results in many errors | ||
Wart.ImplicitParameter), // see wartremover/wartremover#350 & #351 | ||
|
||
Compile / doc / scalacOptions ++= Seq("-groups", "-implicits"), | ||
Compile / compile / wartremoverWarnings -= Wart.ImplicitParameter, // see wartremover/wartremover#350 & #351 | ||
libraryDependencies ++= Seq( | ||
"com.slamdata" %% "slamdata-predef" % "0.0.6", | ||
"com.slamdata" %% "slamdata-predef" % "0.0.7", | ||
"com.github.julien-truffaut" %%% "monocle-core" % monocleVersion % "compile, test", | ||
"org.scalaz" %%% "scalaz-core" % scalazVersion % "compile, test", | ||
"com.github.mpilquist" %%% "simulacrum" % "0.11.0" % "compile, test")) | ||
"com.github.mpilquist" %%% "simulacrum" % "0.15.0" % "compile, test")) | ||
|
||
lazy val publishSettings = commonPublishSettings ++ Seq( | ||
organizationName := "SlamData Inc.", | ||
|
@@ -34,48 +38,59 @@ lazy val publishSettings = commonPublishSettings ++ Seq( | |
url("https://github.com/slamdata/matryoshka"), | ||
"scm:[email protected]:slamdata/matryoshka.git"))) | ||
|
||
lazy val root = Project("root", file(".")) | ||
lazy val root = project.in(file(".")) | ||
.settings(name := "matryoshka") | ||
.settings(standardSettings ++ noPublishSettings: _*) | ||
.settings(transferPublishAndTagResources) | ||
.settings(console := (console in replJVM).value) | ||
.settings( | ||
console := (console in replJVM).value, | ||
crossScalaVersions := Nil, | ||
releaseCrossBuild := false | ||
) | ||
.aggregate( | ||
coreJS, scalacheckJS, testsJS, | ||
coreJVM, scalacheckJVM, testsJVM, | ||
docs) | ||
.enablePlugins(AutomateHeaderPlugin) | ||
|
||
lazy val core = crossProject.in(file("core")) | ||
lazy val core = crossProject(JVMPlatform, JSPlatform).in(file("core")) | ||
.settings(name := "matryoshka-core") | ||
.settings(standardSettings ++ publishSettings: _*) | ||
.enablePlugins(AutomateHeaderPlugin) | ||
|
||
lazy val scalacheck = crossProject | ||
lazy val scalacheck = crossProject(JVMPlatform, JSPlatform) | ||
.dependsOn(core) | ||
.settings(name := "matryoshka-scalacheck") | ||
.settings(standardSettings ++ publishSettings: _*) | ||
.settings(libraryDependencies ++= Seq( | ||
// NB: Needs a version of Scalacheck with rickynils/scalacheck#301. | ||
"org.scalacheck" %% "scalacheck" % "1.14.0-861f58e-SNAPSHOT", | ||
"org.scalaz" %% "scalaz-scalacheck-binding" % (scalazVersion + "-scalacheck-1.13"))) | ||
"org.scalaz" %% "scalaz-scalacheck-binding" % (scalazVersion + "-scalacheck-1.14"))) | ||
.enablePlugins(AutomateHeaderPlugin) | ||
|
||
lazy val tests = crossProject | ||
lazy val tests = crossProject(JVMPlatform, JSPlatform) | ||
.settings(name := "matryoshka-tests") | ||
.dependsOn(core, scalacheck) | ||
.settings(standardSettings ++ noPublishSettings: _*) | ||
.settings(libraryDependencies ++= Seq( | ||
"com.github.julien-truffaut" %% "monocle-law" % monocleVersion % Test, | ||
"org.typelevel" %% "scalaz-specs2" % "0.5.0" % Test, | ||
"org.specs2" %% "specs2-core" % "3.8.7" % Test)) | ||
"org.typelevel" %% "scalaz-specs2" % "0.5.2" % Test, | ||
"org.specs2" %% "specs2-core" % "4.3.5" % Test)) | ||
.enablePlugins(AutomateHeaderPlugin) | ||
|
||
lazy val docs = project | ||
.settings(name := "matryoshka-docs") | ||
.dependsOn(coreJVM) | ||
.settings(standardSettings ++ noPublishSettings: _*) | ||
.settings(tutScalacOptions --= Seq("-Yno-imports", "-Ywarn-unused-import")) | ||
.enablePlugins(MicrositesPlugin) | ||
.dependsOn(coreJVM) | ||
.enablePlugins(MdocPlugin, MicrositesPlugin) | ||
.settings( | ||
//Compile / scalacOptions --= List("-Yno-imports", "-Ywarn-unused-import"), | ||
Compile / scalacOptions -= "-Yno-imports", | ||
Compile / scalacOptions -= "-Ywarn-unused-import", | ||
mdocIn := file("docs/src/main/mdoc/"), | ||
mdocVariables := Map( | ||
"VERSION" -> version.value | ||
) | ||
) | ||
.settings( | ||
micrositeName := "Matryoshka", | ||
micrositeDescription := "Generalized folds, unfolds, and traversals for fixed point data structures in Scala.", | ||
|
@@ -89,7 +104,7 @@ lazy val docs = project | |
/** A project just for the console. | ||
* Applies only the settings necessary for that purpose. | ||
*/ | ||
lazy val repl = crossProject dependsOn (tests % "compile->test") settings standardSettings settings ( | ||
lazy val repl = crossProject(JVMPlatform, JSPlatform) dependsOn (tests % "compile->test") settings standardSettings settings ( | ||
console := (console in Test).value, | ||
scalacOptions --= Seq("-Yno-imports", "-Ywarn-unused-import"), | ||
initialCommands in console += """ | ||
|
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.