Skip to content

Commit e597bcf

Browse files
committed
Add scalafmt
1 parent 99aab14 commit e597bcf

File tree

3 files changed

+18
-9
lines changed

3 files changed

+18
-9
lines changed

.scalafmt.conf

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
version = "2.7.5"
2+
align.preset = more
3+
docstrings = JavaDoc
4+
assumeStandardLibraryStripMargin = true
5+
project.git = true
6+
maxColumn = 100
7+
trailingCommas = multiple

build.sbt

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,19 @@
1-
lazy val root = project.in(file("."))
1+
lazy val root = project
2+
.in(file("."))
23
.aggregate(scalaLibraryNextJVM, scalaLibraryNextJS)
34
.settings(
45
publish / skip := true,
56
// With CrossType.Pure, the root project also picks up the sources in `src`
67
Compile / unmanagedSourceDirectories := Nil,
7-
Test / unmanagedSourceDirectories := Nil,
8+
Test / unmanagedSourceDirectories := Nil,
89
)
910

1011
lazy val scalaLibraryNext = crossProject(JVMPlatform, JSPlatform)
1112
.crossType(CrossType.Pure)
1213
.in(file("."))
1314
.jvmSettings(
14-
libraryDependencies += "junit" % "junit" % "4.13.1" % Test,
15-
libraryDependencies += "com.novocode" % "junit-interface" % "0.11" % Test,
15+
libraryDependencies += "junit" % "junit" % "4.13.1" % Test,
16+
libraryDependencies += "com.novocode" % "junit-interface" % "0.11" % Test,
1617
testOptions += Tests.Argument(TestFrameworks.JUnit, "-a", "-v"),
1718
)
1819
.jsConfigure(_.enablePlugins(ScalaJSJUnitPlugin))
@@ -21,11 +22,11 @@ lazy val scalaLibraryNext = crossProject(JVMPlatform, JSPlatform)
2122
scalaModuleMimaPreviousVersion := None,
2223
scalacOptions ++= Seq("-deprecation", "-feature", "-Werror"),
2324
libraryDependencies ++= Seq(
24-
"org.scalacheck" %%% "scalacheck" % "1.15.0" % Test,
25+
"org.scalacheck" %%% "scalacheck" % "1.15.0" % Test
2526
),
2627
)
2728
.jsSettings(
28-
Test / fork := false,
29+
Test / fork := false
2930
)
3031

3132
lazy val scalaLibraryNextJVM = scalaLibraryNext.jvm

project/plugins.sbt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1-
addSbtPlugin("org.scala-lang.modules" % "sbt-scala-module" % "2.2.3")
2-
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.3.0")
3-
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "1.0.0")
1+
addSbtPlugin("org.scala-lang.modules" % "sbt-scala-module" % "2.2.3")
2+
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.4.2")
3+
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.3.0")
4+
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "1.0.0")

0 commit comments

Comments
 (0)