fix(build): automatically manage trailing commas in ktfmt
This commit is contained in:
parent
09feaf89f6
commit
de6cdfee0e
1 changed files with 6 additions and 2 deletions
|
@ -28,10 +28,14 @@ abstract class KtfmtWorkerAction : WorkAction<KtfmtWorkerParameters> {
|
||||||
Formatter.format(
|
Formatter.format(
|
||||||
FormattingOptions(
|
FormattingOptions(
|
||||||
style = FormattingOptions.Style.GOOGLE,
|
style = FormattingOptions.Style.GOOGLE,
|
||||||
maxWidth = 100,
|
maxWidth = FormattingOptions.DEFAULT_MAX_WIDTH,
|
||||||
|
blockIndent = 2,
|
||||||
continuationIndent = 2,
|
continuationIndent = 2,
|
||||||
|
removeUnusedImports = true,
|
||||||
|
debuggingPrintOpsAfterFormatting = false,
|
||||||
|
manageTrailingCommas = true,
|
||||||
),
|
),
|
||||||
sourceText
|
sourceText,
|
||||||
)
|
)
|
||||||
|
|
||||||
if (!formattedText.contentEquals(sourceText)) {
|
if (!formattedText.contentEquals(sourceText)) {
|
||||||
|
|
Loading…
Reference in a new issue