Skip to content

Commit 0b3f780

Browse files
authored
Merge pull request #11 from scala-native/scalafmt
Add sbt-scalafmt plugin
2 parents 9e2b812 + fef1f75 commit 0b3f780

File tree

16 files changed

+613
-436
lines changed

16 files changed

+613
-436
lines changed

.scalafmt.conf

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
version = "2.0.1"
2+
style = defaultWithAlign
3+
docstrings = JavaDoc
4+
assumeStandardLibraryStripMargin = true
5+
project.excludeFilters = [
6+
scalalib/
7+
]
8+
project.git = true
9+
runner.dialect = Scala211

build.sbt

Lines changed: 45 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
1-
21
homepage := Some(url("https://github.com/scala-native/scala-native-loop"))
3-
licenses := Seq("Apache 2.0" -> url("http://www.apache.org/licenses/LICENSE-2.0"))
2+
licenses := Seq(
3+
"Apache 2.0" -> url("http://www.apache.org/licenses/LICENSE-2.0")
4+
)
45
publishMavenStyle := true
56
publishArtifact in Test := false
6-
pomIncludeRepository := { _ => false }
7+
pomIncludeRepository := { _ =>
8+
false
9+
}
710
publishTo in ThisBuild := {
811
val nexus = "https://oss.sonatype.org/"
912
if (isSnapshot.value)
1013
Some("snapshots" at nexus + "content/repositories/snapshots")
1114
else
12-
Some("releases" at nexus + "service/local/staging/deploy/maven2")
15+
Some("releases" at nexus + "service/local/staging/deploy/maven2")
1316
}
1417
scmInfo := Some(
1518
ScmInfo(
@@ -18,7 +21,12 @@ scmInfo := Some(
1821
)
1922
)
2023
developers := List(
21-
Developer("rwhaling", "Richard Whaling", "[email protected]", url("http://whaling.dev"))
24+
Developer(
25+
"rwhaling",
26+
"Richard Whaling",
27+
28+
url("http://whaling.dev")
29+
)
2230
)
2331

2432
lazy val commonSettings = Seq(
@@ -33,51 +41,51 @@ lazy val commonSettings = Seq(
3341
)
3442

3543
lazy val core = (project in file("core"))
36-
.settings(name := "native-loop-core")
37-
.settings(commonSettings:_*)
38-
.settings(skip in publish := false)
39-
.settings(skip in publishLocal := false)
40-
.enablePlugins(ScalaNativePlugin)
44+
.settings(name := "native-loop-core")
45+
.settings(commonSettings: _*)
46+
.settings(skip in publish := false)
47+
.settings(skip in publishLocal := false)
48+
.enablePlugins(ScalaNativePlugin)
4149

4250
lazy val pipe = (project in file("pipe"))
43-
.settings(commonSettings:_*)
44-
.enablePlugins(ScalaNativePlugin)
45-
.dependsOn(core)
51+
.settings(commonSettings: _*)
52+
.enablePlugins(ScalaNativePlugin)
53+
.dependsOn(core)
4654

4755
lazy val client = (project in file("client"))
48-
.settings(commonSettings:_*)
49-
.enablePlugins(ScalaNativePlugin)
50-
.dependsOn(core)
56+
.settings(commonSettings: _*)
57+
.enablePlugins(ScalaNativePlugin)
58+
.dependsOn(core)
5159

5260
lazy val server = (project in file("server"))
53-
.settings(commonSettings:_*)
54-
.enablePlugins(ScalaNativePlugin)
55-
.dependsOn(core)
61+
.settings(commonSettings: _*)
62+
.enablePlugins(ScalaNativePlugin)
63+
.dependsOn(core)
5664

5765
lazy val scalaJsCompat = (project in file("scalajs-compat"))
58-
.settings(name := "native-loop-js-compat")
59-
.settings(commonSettings:_*)
60-
.settings(skip in publish := false)
61-
.settings(skip in publishLocal := false)
62-
.enablePlugins(ScalaNativePlugin)
63-
.dependsOn(core)
66+
.settings(name := "native-loop-js-compat")
67+
.settings(commonSettings: _*)
68+
.settings(skip in publish := false)
69+
.settings(skip in publishLocal := false)
70+
.enablePlugins(ScalaNativePlugin)
71+
.dependsOn(core)
6472

6573
lazy val serverExample = (project in file("examples/server"))
66-
.settings(commonSettings:_*)
67-
.enablePlugins(ScalaNativePlugin)
68-
.dependsOn(core,server,client)
74+
.settings(commonSettings: _*)
75+
.enablePlugins(ScalaNativePlugin)
76+
.dependsOn(core, server, client)
6977

7078
lazy val pipeExample = (project in file("examples/pipe"))
71-
.settings(commonSettings:_*)
72-
.enablePlugins(ScalaNativePlugin)
73-
.dependsOn(core,pipe,client)
79+
.settings(commonSettings: _*)
80+
.enablePlugins(ScalaNativePlugin)
81+
.dependsOn(core, pipe, client)
7482

7583
lazy val curlExample = (project in file("examples/curl"))
76-
.settings(commonSettings:_*)
77-
.enablePlugins(ScalaNativePlugin)
78-
.dependsOn(core,client)
84+
.settings(commonSettings: _*)
85+
.enablePlugins(ScalaNativePlugin)
86+
.dependsOn(core, client)
7987

8088
lazy val timerExample = (project in file("examples/timer"))
81-
.settings(commonSettings:_*)
82-
.enablePlugins(ScalaNativePlugin)
83-
.dependsOn(core)
89+
.settings(commonSettings: _*)
90+
.enablePlugins(ScalaNativePlugin)
91+
.dependsOn(core)

0 commit comments

Comments
 (0)