Skip to content

Commit

Permalink
Merge pull request #1989 from satorg/introduce-scalafmt
Browse files Browse the repository at this point in the history
Add 'scalafmt' to the project
  • Loading branch information
jatcwang authored Jul 9, 2024
2 parents a93991d + 0ede13d commit d8a2afd
Show file tree
Hide file tree
Showing 219 changed files with 3,733 additions and 3,129 deletions.
5 changes: 5 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Introduce scalafmt [PR #1989]
4eab00000c6f22d0d0fee379f234e287dc7649bd
8c04f656ec5e21d6142ebde4539a00003b27a499
f6e03013f4c4a29074f528ac468129bdd2df63d3
13d6c997bb231bbae2bb1a9427d0fc4eb226e853
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,10 @@ jobs:
- name: Check that workflows are up to date
run: sbt githubWorkflowCheck

- name: Check formatting
if: matrix.java == 'temurin@11' && matrix.os == 'ubuntu-latest'
run: sbt '++ ${{ matrix.scala }}' scalafmtCheckAll 'project /' scalafmtSbtCheck

- name: Test
run: sbt '++ ${{ matrix.scala }}' freeGen2 test

Expand Down
32 changes: 32 additions & 0 deletions .scalafmt.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
version=3.8.2
maxColumn = 120
assumeStandardLibraryStripMargin = true

preset = default
align {
stripMargin = true
}

danglingParentheses {
callSite = false
}

newlines {
source = keep
}

runner.dialect = scala213source3
fileOverride {
"glob:**/*.sbt" {
runner.dialect = sbt1
}
"glob:**/src/{main,test}/scala-2.13-/**" {
runner.dialect = scala212source3
}
"glob:**/src/{main,test}/scala-3/**" {
runner.dialect = scala3
}
}
project.excludeFilters = [
"scalafix/*"
]
Loading

0 comments on commit d8a2afd

Please sign in to comment.