Skip to content

Commit 12565be

Browse files
Added explicit sbt root (aggregation) project
1 parent 7e06c7e commit 12565be

File tree

1 file changed

+41
-10
lines changed

1 file changed

+41
-10
lines changed

build.sbt

Lines changed: 41 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,8 @@ val ReduxDevToolsVersion = "^2.13.0"
99

1010
val StaticTagsVersion = "2.6.1"
1111

12-
publishArtifact in ThisBuild := false
13-
1412
val commonSettings = Seq(
1513
organization := "org.scommons.shogowada",
16-
name := "scalajs-reactjs",
1714

1815
crossScalaVersions := Seq("2.12.2", "2.13.1"),
1916
scalaVersion := "2.12.2",
@@ -24,6 +21,7 @@ val commonSettings = Seq(
2421
//resolvers += "Sonatype Snapshots" at "https://oss.sonatype.org/content/repositories/snapshots/",
2522

2623
sonatypeProfileName := "org.scommons",
24+
publishArtifact := false,
2725
publishMavenStyle := true,
2826
publishArtifact in Test := false,
2927
publishTo := {
@@ -63,9 +61,42 @@ val commonSettings = Seq(
6361
}
6462
)
6563

64+
lazy val root = (project in file("."))
65+
.settings(commonSettings: _*)
66+
.settings(
67+
crossScalaVersions := Nil, //must be set to Nil on the aggregating project
68+
skip in publish := true,
69+
publish := ((): Unit),
70+
publishLocal := ((): Unit),
71+
publishM2 := ((): Unit)
72+
)
73+
.aggregate(
74+
core,
75+
history,
76+
router,
77+
routerDom,
78+
redux,
79+
reduxDevTools,
80+
routerRedux,
81+
exampleCustomVirtualDOM,
82+
exampleHelloWorld,
83+
exampleHelloWorldFunction,
84+
exampleInteractiveHelloWorld,
85+
exampleLifecycle,
86+
exampleReduxDevTools,
87+
exampleReduxMiddleware,
88+
exampleRouter,
89+
exampleRouterRedux,
90+
exampleStyle,
91+
exampleTodoApp,
92+
exampleTodoAppRedux,
93+
exampleTest
94+
)
95+
6696
lazy val core = project.in(file("core"))
6797
.settings(commonSettings: _*)
6898
.settings(
99+
name := "scalajs-reactjs",
69100
libraryDependencies ++= Seq(
70101
"org.scala-js" %%% "scalajs-dom" % "0.9.8",
71102
"org.scommons.shogowada" %%% "statictags" % StaticTagsVersion
@@ -97,7 +128,7 @@ lazy val history = project.in(file("history"))
97128
lazy val router = project.in(file("router"))
98129
.settings(commonSettings: _*)
99130
.settings(
100-
name += "-router",
131+
name := "scalajs-reactjs-router",
101132
npmDependencies in Compile ++= Seq(
102133
"react-router" -> ReactRouterVersion
103134
),
@@ -111,7 +142,7 @@ lazy val router = project.in(file("router"))
111142
lazy val routerDom = project.in(file("router-dom"))
112143
.settings(commonSettings: _*)
113144
.settings(
114-
name += "-router-dom",
145+
name := "scalajs-reactjs-router-dom",
115146
npmDependencies in Compile ++= Seq(
116147
"react-router-dom" -> ReactRouterVersion
117148
),
@@ -125,7 +156,7 @@ lazy val routerDom = project.in(file("router-dom"))
125156
lazy val redux = project.in(file("redux"))
126157
.settings(commonSettings: _*)
127158
.settings(
128-
name += "-redux",
159+
name := "scalajs-reactjs-redux",
129160
npmDependencies in Compile ++= Seq(
130161
"react-redux" -> ReactReduxVersion,
131162
"redux" -> ReduxVersion
@@ -140,7 +171,7 @@ lazy val redux = project.in(file("redux"))
140171
lazy val reduxDevTools = project.in(file("redux-devtools"))
141172
.settings(commonSettings: _*)
142173
.settings(
143-
name += "-redux-devtools",
174+
name := "scalajs-reactjs-redux-devtools",
144175
npmDependencies in Compile ++= Seq(
145176
"redux-devtools-extension" -> ReduxDevToolsVersion
146177
),
@@ -154,7 +185,7 @@ lazy val reduxDevTools = project.in(file("redux-devtools"))
154185
lazy val routerRedux = project.in(file("router-redux"))
155186
.settings(commonSettings: _*)
156187
.settings(
157-
name += "-router-redux",
188+
name := "scalajs-reactjs-router-redux",
158189
npmDependencies in Compile ++= Seq(
159190
"react-router-redux" -> ReactRouterReduxVersion
160191
),
@@ -166,7 +197,7 @@ lazy val routerRedux = project.in(file("router-redux"))
166197
.dependsOn(core, history, router, redux)
167198

168199
val exampleCommonSettings = commonSettings ++ Seq(
169-
name += "-example",
200+
name := "scalajs-reactjs-example",
170201
scalaJSUseMainModuleInitializer := true,
171202
(unmanagedResourceDirectories in Compile) += baseDirectory.value / "src" / "main" / "webapp"
172203
)
@@ -272,7 +303,7 @@ lazy val exampleTest = project.in(file("example") / "test")
272303
.settings(commonSettings: _*)
273304
.settings(Defaults.itSettings: _*)
274305
.settings(
275-
name += "-example-test",
306+
name := "scalajs-reactjs-example-test",
276307
libraryDependencies ++= Seq(
277308
"org.eclipse.jetty" % "jetty-server" % "9.+",
278309

0 commit comments

Comments
 (0)