Skip to content

Commit e9584dd

Browse files
jtjeferreirarozza
authored andcommitted
Update Spotless and Scalafmt
JAVA-4181
1 parent 4b158d0 commit e9584dd

File tree

2 files changed

+15
-9
lines changed

2 files changed

+15
-9
lines changed

build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ buildscript {
3030

3131
// Scala plugins
3232
classpath "com.adtran:scala-multiversion-plugin:2.0.4"
33-
classpath "com.diffplug.spotless:spotless-plugin-gradle:3.27.1"
33+
classpath "com.diffplug.spotless:spotless-plugin-gradle:6.3.0"
3434

3535
// Test logging plugin
3636
classpath 'com.adarshr:gradle-test-logger-plugin:2.1.0'
@@ -95,7 +95,7 @@ configure(scalaProjects) {
9595
apply plugin: 'scala'
9696
apply plugin: 'idea'
9797
apply plugin: "com.adtran.scala-multiversion-plugin"
98-
apply plugin: "com.diffplug.gradle.spotless"
98+
apply plugin: "com.diffplug.spotless"
9999

100100
group = 'org.mongodb.scala'
101101

@@ -122,7 +122,7 @@ configure(scalaProjects) {
122122

123123
spotless {
124124
scala {
125-
scalafmt('2.0.0').configFile("$configDir/scala/scalafmt.conf")
125+
scalafmt().configFile("$configDir/scala/scalafmt.conf")
126126
}
127127
}
128128
compileScala.dependsOn('spotlessApply')

config/scala/scalafmt.conf

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,16 @@
1-
style = defaultWithAlign
1+
version = "3.4.3"
2+
runner.dialect = scala213
23

3-
align.tokens = [off]
4-
align = some
5-
danglingParentheses = true
6-
docstrings = JavaDoc
4+
preset = default
5+
6+
danglingParentheses.preset = true
7+
docstrings.style = keep
8+
#docstrings.style = Asterisk
9+
#docstrings.wrap = no
710
maxColumn = 120
811
rewrite.rules = [SortImports]
9-
newlines.alwaysBeforeTopLevelStatements = false
12+
newlines.topLevelStatements = []
13+
newlines.source=keep
14+
newlines.implicitParamListModifierPrefer=before
15+
1016
spaces.inImportCurlyBraces = true

0 commit comments

Comments
 (0)