Skip to content

Commit

Permalink
Merge pull request #877 from kitbellew/877
Browse files Browse the repository at this point in the history
Formatting: adjust scalafmt configuration
  • Loading branch information
kitbellew authored Jan 18, 2025
2 parents 492f7c6 + 613079b commit 779870e
Show file tree
Hide file tree
Showing 132 changed files with 2,092 additions and 3,167 deletions.
3 changes: 3 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
# Scala Steward: Reformat with sbt-java-formatter 0.8.0
9e5e7610a81938d804d8edf533844b03ef125b5a

# adjust scalafmt config
2087aa17546b6526511b5848faa0aa9819432181
63 changes: 54 additions & 9 deletions .scalafmt.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,62 @@ version = "3.8.5"

assumeStandardLibraryStripMargin = true

align {
preset = none
stripMargin = true
}

// Docstring wrapping breaks doctests
docstrings.wrap = false
docstrings.style = Asterisk
docstrings {
wrap = false
style = Asterisk
}

project.git=true
project.excludeFilters = [
"LinesSuite.scala"
]
project {
git = true
excludeFilters = [
"LinesSuite.scala"
]
layout = StandardConvention
}
runner.dialect = scala212
fileOverride {
"glob:**/src/{main,test}/scala-3/**" {
runner.dialect = scala3

newlines {
avoidForSimpleOverflow = all
inInterpolation = avoid
source = fold
}

rewrite {
rules = [
AvoidInfix,
Imports,
RedundantBraces,
RedundantParens,
SortModifiers,
]
imports {
expand = true
sort = ascii
groups = [
["munit\\..*"],
["sbt\\..*"],
["java.?\\..*"],
["scala\\..*"],
["org\\..*"],
["com\\..*"],
]
}
redundantBraces {
preset = all
oneStatApply {
parensMaxSpan = 300
bracesMinSpan = 300
}
}
redundantParens {
preset = all
}
sortModifiers.preset = styleGuide
trailingCommas.style = multiple
}
Loading

0 comments on commit 779870e

Please sign in to comment.