Skip to content

Commit

Permalink
bump to sbt-scalafmt 2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
eed3si9n committed May 13, 2019
1 parent 08be8bc commit 41100dd
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 3 deletions.
11 changes: 11 additions & 0 deletions .scalafmt.conf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
version = 2.0.0-RC7
maxColumn = 100
project.git = true
project.excludeFilters = [ /sbt-test/, /input_sources/, /contraband-scala/ ]
Expand All @@ -8,3 +9,13 @@ docstrings = JavaDoc

# This also seems more idiomatic to include whitespace in import x.{ yyy }
spaces.inImportCurlyBraces = true

# This is more idiomatic Scala.
# http://docs.scala-lang.org/style/indentation.html#methods-with-numerous-arguments
align.openParenCallSite = false
align.openParenDefnSite = false

# For better code clarity
danglingParentheses = true

trailingCommas = preserve
2 changes: 1 addition & 1 deletion bin/run-ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ sbt -Dfile.encoding=UTF-8 \
-J-XX:ReservedCodeCacheSize=512M \
-J-Xms1024M -J-Xmx4096M -J-server \
"$PROJECT_ROOT/mimaReportBinaryIssues" \
scalafmtCheck \
scalafmtCheckAll \
whitesourceCheckPolicies \
"$PROJECT_ROOT/test:compile" \
crossTestBridges \
Expand Down
3 changes: 2 additions & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ ThisBuild / version := {
}
}
ThisBuild / licenses := List(("Apache-2.0", url("https://www.apache.org/licenses/LICENSE-2.0")))
ThisBuild / scalafmtOnCompile := true
ThisBuild / Test / scalafmtOnCompile := true

def buildLevelSettings: Seq[Setting[_]] = Seq(
// https://github.com/sbt/sbt-git/issues/109
Expand Down Expand Up @@ -63,7 +65,6 @@ def buildLevelSettings: Seq[Setting[_]] = Seq(
homepage := Some(url("https://github.com/sbt/zinc")),
developers +=
Developer("jvican", "Jorge Vicente Cantero", "@jvican", url("https://github.com/jvican")),
scalafmtOnCompile := true,
)

def commonSettings: Seq[Setting[_]] = Seq(
Expand Down
2 changes: 1 addition & 1 deletion project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
scalaVersion := "2.12.8"

addSbtPlugin("org.scala-sbt" % "sbt-houserules" % "0.3.9")
addSbtPlugin("com.geirsson" % "sbt-scalafmt" % "1.5.1")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.0.0")
addSbtPlugin("org.scala-sbt" % "sbt-contraband" % "0.4.1")
addSbtPlugin("pl.project13.scala" % "sbt-jmh" % "0.3.3")
addSbtPlugin("de.heikoseeberger" % "sbt-header" % "3.0.2")
Expand Down

0 comments on commit 41100dd

Please sign in to comment.