From 05ac8bf6a9e2113aaea1998ba5d26f1800ce9a34 Mon Sep 17 00:00:00 2001 From: Sergey Morgunov Date: Wed, 18 May 2022 17:57:23 +0300 Subject: [PATCH] Sync Scalafmt settings between all repositories --- .github/sync.yml | 5 +++++ .github/workflows/sync.yml | 1 + .scalafmt.conf | 12 ++++++++++++ 3 files changed, 18 insertions(+) create mode 100644 .scalafmt.conf diff --git a/.github/sync.yml b/.github/sync.yml index 016a689..701b8f1 100644 --- a/.github/sync.yml +++ b/.github/sync.yml @@ -32,3 +32,8 @@ group: # playframework/play-java-angular-seed # playframework/play-scala-angular-seed + # Scalafmt settings + - files: + - .scalafmt.conf + repos: | + playframework/play-soap diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index df4887c..4045fc5 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -3,6 +3,7 @@ on: push: branches: - main + - sync-scalafmt # TODO: remove before merge jobs: sync: runs-on: ubuntu-20.04 diff --git a/.scalafmt.conf b/.scalafmt.conf new file mode 100644 index 0000000..193e8c9 --- /dev/null +++ b/.scalafmt.conf @@ -0,0 +1,12 @@ +align = true +assumeStandardLibraryStripMargin = true +danglingParentheses = true +docstrings = JavaDoc +maxColumn = 120 +project.excludeFilters += core/play/src/main/scala/play/core/hidden/ObjectMappings.scala # Ooohhh 😞 +project.git = true +rewrite.rules = [ AvoidInfix, ExpandImportSelectors, RedundantParens, SortModifiers, PreferCurlyFors ] +rewrite.sortModifiers.order = [ "private", "protected", "final", "sealed", "abstract", "implicit", "override", "lazy" ] +spaces.inImportCurlyBraces = true # more idiomatic to include whitepsace in import x.{ yyy } +trailingCommas = preserve +version = 2.3.2