-
Notifications
You must be signed in to change notification settings - Fork 0
/
.scalafmt.conf
59 lines (51 loc) · 1.1 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
52
53
54
55
56
57
58
59
version = 3.8.3
runner.dialect = scala3
// 最大宽度
maxColumn = 150
encoding = UTF-8
lineEndings = unix
docstrings.style = keep
// 函数调用换行缩进
continuationIndent.callSite = 2
// 函数定义换行缩进
continuationIndent.defnSite = 4
newlines.beforeCurlyLambdaParams = "never"
// 多行字符串
assumeStandardLibraryStripMargin = true
align.tokenCategory {
Equals = Assign
LeftArrow = Assign
}
align = more
align.arrowEnumeratorGenerator = true
align.tokenCategory.Equals = Assign
align.tokenCategory.LeftArrow = Assign
align.tokens = [
"//"
"="
"==>"
"<-"
"->"
{code = "=>", owner = "Case"}
{code = "extends", owner = "Defn.(Class|Trait|Object)}|Template|Defn.EnumCase"}
{code = "=", owner = "(Enumerator.Val|Defn.(Va(l|r)|Def|Type))"}
// {code = ":", owner = "(applyInfix|Defn.(Va(l|r)|Def|Type))"}
":"
":="
"=:"
"+="
"-="
"*="
"%"
"%%"
"%%%"
{code = "{", owner = "Template"}
{code = "}", owner = "Template"}
]
// <-
align.arrowEnumeratorGenerator = true
align.openParenCallSite = true
align.treeCategory {
Case: Assign
"Enumerator.Generator": Assign
}