forked from typelevel/cats
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
21d49b4
commit 4f6d5c2
Showing
2 changed files
with
8 additions
and
15 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,7 @@ lazy val scoverageSettings = Seq( | |
) | ||
|
||
organization in ThisBuild := "org.typelevel" | ||
scalafixDependencies in ThisBuild += "org.typelevel" %% "simulacrum-scalafix" % "0.1.0" | ||
|
||
val isTravisBuild = settingKey[Boolean]("Flag indicating whether the current build is running under Travis") | ||
val crossScalaVersionsFromTravis = settingKey[Seq[String]]("Scala versions set in .travis.yml as scala_version_XXX") | ||
|
@@ -67,13 +68,7 @@ lazy val commonSettings = commonScalaVersionSettings ++ Seq( | |
) ++ warnUnusedImport | ||
|
||
def macroDependencies(scalaVersion: String) = | ||
CrossVersion.partialVersion(scalaVersion) match { | ||
case Some((2, minor)) if minor < 13 => | ||
Seq( | ||
compilerPlugin(("org.scalamacros" %% "paradise" % "2.1.1").cross(CrossVersion.patch)) | ||
) | ||
case _ => Seq() | ||
} | ||
Seq("org.scala-lang" % "scala-reflect" % scalaVersion % Provided) | ||
|
||
lazy val catsSettings = Seq( | ||
incOptions := incOptions.value.withLogRecompileOnMacro(false), | ||
|
@@ -83,10 +78,9 @@ lazy val catsSettings = Seq( | |
) ++ commonSettings ++ publishSettings ++ scoverageSettings ++ simulacrumSettings | ||
|
||
lazy val simulacrumSettings = Seq( | ||
libraryDependencies ++= Seq( | ||
scalaOrganization.value % "scala-reflect" % scalaVersion.value % Provided, | ||
"org.typelevel" %%% "simulacrum" % "1.0.0" % Provided | ||
), | ||
addCompilerPlugin(scalafixSemanticdb), | ||
scalacOptions ++= Seq(s"-P:semanticdb:targetroot:${baseDirectory.value}/target/.semanticdb", "-Yrangepos"), | ||
libraryDependencies += "org.typelevel" %% "simulacrum-scalafix-annotations" % "0.1.0", | ||
pomPostProcess := { (node: xml.Node) => | ||
new RuleTransformer(new RewriteRule { | ||
override def transform(node: xml.Node): Seq[xml.Node] = node match { | ||
|
@@ -216,7 +210,7 @@ lazy val docSettings = Seq( | |
) ++ (if (priorTo2_13(scalaVersion.value)) | ||
Seq("-Yno-adapted-args") | ||
else | ||
Seq("-Ymacro-annotations")), | ||
Nil), | ||
scalacOptions in Tut ~= (_.filterNot(Set("-Ywarn-unused-import", "-Ywarn-unused:imports", "-Ywarn-dead-code"))), | ||
git.remoteRepo := "[email protected]:typelevel/cats.git", | ||
includeFilter in makeSite := "*.html" | "*.css" | "*.png" | "*.jpg" | "*.gif" | "*.js" | "*.swf" | "*.yml" | "*.md" | "*.svg", | ||
|
@@ -795,9 +789,7 @@ def commonScalacOptions(scalaVersion: String) = | |
"-Xfuture" | ||
) | ||
else | ||
Seq( | ||
"-Ymacro-annotations" | ||
)) | ||
Nil) | ||
|
||
def priorTo2_13(scalaVersion: String): Boolean = | ||
CrossVersion.partialVersion(scalaVersion) match { | ||
|
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