Skip to content

Commit 186096d

Browse files
authored
Merge pull request #495 from tpolecat/update-deps
update deps
2 parents 69c3595 + 494e326 commit 186096d

File tree

4 files changed

+34
-23
lines changed

4 files changed

+34
-23
lines changed

build.sbt

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
// Our Scala versions.
44
lazy val `scala-2.12` = "2.12.13"
5-
lazy val `scala-2.13` = "2.13.5"
5+
lazy val `scala-2.13` = "2.13.6"
66
lazy val `scala-3.0` = "3.0.0"
77

88
// This is used in a couple places
@@ -52,7 +52,7 @@ lazy val commonSettings = Seq(
5252
"-doc-source-url", "https://github.com/tpolecat/skunk/blob/v" + version.value + "€{FILE_PATH}.scala",
5353
),
5454
libraryDependencies ++= Seq(
55-
compilerPlugin("org.typelevel" %% "kind-projector" % "0.11.3" cross CrossVersion.full),
55+
compilerPlugin("org.typelevel" %% "kind-projector" % "0.13.0" cross CrossVersion.full),
5656
).filterNot(_ => scalaVersion.value.startsWith("3.")),
5757

5858
// Coverage Exclusions
@@ -134,17 +134,10 @@ lazy val circe = project
134134
.settings(commonSettings)
135135
.settings(
136136
name := "skunk-circe",
137-
libraryDependencies ++= {
138-
lazy val circeVersion: String =
139-
scalaVersion.value match {
140-
case `scala-3.0` => "0.14.0-M7"
141-
case _ => "0.13.0"
142-
}
143-
Seq(
144-
"io.circe" %% "circe-core" % circeVersion,
145-
"io.circe" %% "circe-parser" % circeVersion
146-
)
147-
}
137+
libraryDependencies ++= Seq(
138+
"io.circe" %% "circe-core" % "0.14.1",
139+
"io.circe" %% "circe-parser" % "0.14.1"
140+
)
148141
)
149142

150143
lazy val tests = project

modules/docs/src/main/scala/mdoc/Main.scala

Lines changed: 26 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (c) 2018-2020 by Rob Norris
1+
// Copyright (c) 2018-2021 by Rob Norris
22
// This software is licensed under the MIT License (MIT).
33
// For more information see LICENSE or https://opensource.org/licenses/MIT
44

@@ -64,11 +64,11 @@ object Main {
6464

6565
// copy-pasted from mdoc source, adding `pprinter` as an arg
6666
case class ReplVariablePrinter(
67-
leadingNewline: Boolean = true,
68-
width: Int = 80,
69-
height: Int = 80,
70-
indent: Int = 2,
71-
pprinter: PPrinter = PPrinter.BlackWhite,
67+
leadingNewline: Boolean = true,
68+
width: Int = 80,
69+
height: Int = 80,
70+
indent: Int = 2,
71+
pprinter: PPrinter = PPrinter.BlackWhite,
7272
) extends (_root_.mdoc.Variable => String) {
7373

7474
override def apply(binder: Variable): String = {
@@ -85,7 +85,7 @@ case class ReplVariablePrinter(
8585
.append(binder.staticType)
8686
.append(" = ")
8787
if (binder.isToString) {
88-
Renderer.appendMultiline(sb, binder.runtimeValue.toString)
88+
appendMultiline(sb, binder.runtimeValue.toString)
8989
} else {
9090
val heightOverride = binder.mods.heightOverride
9191
val widthOverride = binder.mods.widthOverride
@@ -99,11 +99,29 @@ case class ReplVariablePrinter(
9999
)
100100
lines.foreach { lineStr =>
101101
val line = lineStr.plainText
102-
Renderer.appendMultiline(sb, line)
102+
appendMultiline(sb, line)
103103
}
104104
}
105105
baos.toString()
106106
}
107107
}
108108

109+
def appendMultiline(sb: PrintStream, string: String): Unit = {
110+
appendMultiline(sb, string, string.length)
111+
}
112+
113+
def appendMultiline(sb: PrintStream, string: String, N: Int): Unit = {
114+
var i = 0
115+
while (i < N) {
116+
string.charAt(i) match {
117+
case '\n' =>
118+
sb.append("\n// ")
119+
case ch =>
120+
sb.append(ch)
121+
}
122+
i += 1
123+
}
124+
}
109125
}
126+
127+

modules/docs/src/main/scala/mdoc/package.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (c) 2018-2020 by Rob Norris
1+
// Copyright (c) 2018-2021 by Rob Norris
22
// This software is licensed under the MIT License (MIT).
33
// For more information see LICENSE or https://opensource.org/licenses/MIT
44

project/plugins.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@ addSbtPlugin("com.typesafe.sbt" % "sbt-site" % "1.4.1")
55
addSbtPlugin("com.typesafe.sbt" % "sbt-ghpages" % "0.6.3")
66
addSbtPlugin("com.timushev.sbt" % "sbt-updates" % "0.5.3")
77
addSbtPlugin("io.github.davidgregory084" % "sbt-tpolecat" % "0.1.20")
8-
addSbtPlugin("org.scalameta" % "sbt-mdoc" % "2.2.20")
8+
addSbtPlugin("org.scalameta" % "sbt-mdoc" % "2.2.21")
99
addSbtPlugin("org.scoverage" % "sbt-scoverage" % "1.8.2")
1010
addSbtPlugin("ch.epfl.scala" % "sbt-eviction-rules" % "1.0.0-RC1")

0 commit comments

Comments
 (0)