forked from enso-org/enso
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.scalafmt.conf
42 lines (33 loc) · 992 Bytes
/
.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
// Scala Formatting Configuration for Enso
// All Scala files should be reformatted through this formatter before being
// committed to the repositories.
version = "2.0.0-RC8"
// Wrapping and Alignment
align = some
align.openParenCallSite = false
align.openParenDefnSite = false
maxColumn = 80
// Comments and Documentation
docstrings = "scaladoc"
// Indentation
continuationIndent.callSite = 2
continuationIndent.defnSite = 4
// Newlines
newlines.alwaysBeforeElseAfterCurlyIf = true
newlines.alwaysBeforeTopLevelStatements = false
// Rewrite Rules
rewrite.rules = [
ExpandImportSelectors,
PreferCurlyFors,
RedundantParens,
SortModifiers,
]
rewrite.sortModifiers.order = [
"implicit", "final", "sealed", "abstract",
"override", "private", "protected", "lazy"
]
// Multiline Configuration
verticalMultiline.atDefnSite = true
verticalMultiline.arityThreshold = 5
// Please remember that `//format: off` and `//format: on` directives should be
// used sparingly, if at all.