generated from finos/software-project-blueprint
-
Notifications
You must be signed in to change notification settings - Fork 29
/
Copy path.scalafmt.conf
41 lines (33 loc) · 1.07 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
version = 3.8.4
maxColumn = 120
runner.dialect = scala3
rewrite.rules = [RedundantBraces]
assumeStandardLibraryStripMargin = true
align.stripMargin = true
align.preset = more
# If I've inserted extra newlines I know what I'm doing, don't wrap them back.
newlines.source = keep
# Don't change braces in one-liners to parens e.g. don't change this: `test("foo") { assertEquals(x,y) }`
# to this `test("foo")(assertEquals(x,y))`. The `rewrite.rules = [RedundantBraces]` will introduce this behavior
# unless you add the below option.
rewrite.redundantBraces.parensForOneLineApply = false
# Align defs with annotations e.g. change:
# @Anno1 def foo: String
# @Anno123 def bar: String
# into:
# @Anno1 def foo: String
# @Anno123 def bar: String
align.tokens."+" = [{
code = "def"
owners = [{regex = "Decl\\.Def"}]
}]
indent.main = 2
indent.significant = 2
project.git = true
project.excludeFilters = [
# ".*-scala-3.*",
# Dont touch metals.sbt files since they're auto generated!
"metals.sbt"
]
# Use the more typical style of doc strings
docstrings.style = Asterisk