-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy path.scalafmt.conf
51 lines (42 loc) · 1.36 KB
/
.scalafmt.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
version = 3.8.3
project.git = true
maxColumn = 130
trailingCommas = always
continuationIndent {
callSite = 2
defnSite = 2
}
align.preset = some
align.tokenCategory {
LeftArrow = Assign
Equals = Assign
}
# Mostly subset of `align.preset=more`, but with extra settings for `=`
# For all settings see `AlignToken#default` in
# /~https://github.com/scalameta/scalafmt/blob/master/scalafmt-core/shared/src/main/scala/org/scalafmt/config/AlignToken.scala
align.tokens."+" = [
{ code = "%", owner = "Term.ApplyInfix" }
{ code = "%%", owner = "Term.ApplyInfix" }
{ code = "%%%", owner = "Term.ApplyInfix" }
{ code = "=>", owner = "(Case|Term.Function)" }
{ code = "<-", owner = "Enumerator.Generator" }
{ code = "=", owner = "(Defn.Val|Defn.Var|Type|Def|Enumerator.Val|Assign|Term.Param)" } # Defn.Val is mostly for Dependencies.scala,
{ code = "->", owner = "Term.ApplyInfix" }
]
newlines.implicitParamListModifierPrefer = before
newlines.beforeCurlyLambdaParams = multilineWithCaseOnly
indentOperator.topLevelOnly = true
docstrings.style = keep
docstrings.blankFirstLine = keep
includeCurlyBraceInSelectChains = true
includeNoParensInSelectChains = true
optIn.breakChainOnFirstMethodDot = true
runner.dialect = scala213source3
fileOverride {
"glob:**/*.sbt" {
runner.dialect = sbt1
}
"glob:**/src/{main,test}/scala-3/**" {
runner.dialect = scala3
}
}