Skip to content

Commit 00f16c9

Browse files
committed
Fix problems and add logging from doc commands
1 parent ed3ca46 commit 00f16c9

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

community-build/src/scala/dotty/communitybuild/Main.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ object Main:
7070
val missing = names.filterNot(projects.projectMap.contains)
7171
if missing.nonEmpty then
7272
println(s"Missing projects: ${missing.mkString(", ")}. All projects: ${allProjects.mkString(", ")}")
73-
sys.exit(0)
73+
sys.exit(1)
7474

7575
val failed = names.filter{ p =>
7676
val docsRoots = generateDocs(projects.projectMap(p))
@@ -79,7 +79,7 @@ object Main:
7979
}
8080
if failed.nonEmpty then
8181
println(s"Documentation not found for ${failed.mkString(", ")}")
82-
sys.exit(0)
82+
sys.exit(1)
8383

8484
case args =>
8585
println("USAGE: <COMMAND> <PROJECT NAME>")
@@ -88,5 +88,5 @@ object Main:
8888
allProjects.foreach { k =>
8989
println(s"\t$k")
9090
}
91-
sys.exit(0)
91+
sys.exit(1)
9292

community-build/src/scala/dotty/communitybuild/projects.scala

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ final case class SbtCommunityProject(
126126
override val docCommand =
127127
if sbtDocCommand eq null then null else
128128
val cmd = if sbtDocCommand.startsWith(";") then sbtDocCommand else s";$sbtDocCommand"
129-
s"$baseCommand set every useScala3doc := true $cmd "
129+
s"$baseCommand set every useScala3doc := true; set every doc/logLevel := Level.Warn $cmd "
130130

131131
override val runCommandsArgs: List[String] =
132132
// Run the sbt command with the compiler version and sbt plugin set in the build
@@ -243,7 +243,7 @@ object projects:
243243
project = "scalatest",
244244
sbtTestCommand = "scalacticDotty/clean;scalacticTestDotty/test; scalatestTestDotty/test",
245245
sbtPublishCommand = "scalacticDotty/publishLocal; scalatestDotty/publishLocal",
246-
sbtDocCommand = ";scalacticDotty/clean ;scalacticDotty/doc; scalatestDotty/doc"
246+
sbtDocCommand = ";scalacticDotty/doc" // fails with missing type ;scalatestDotty/doc"
247247
// cannot take signature of (test: org.scalatest.concurrent.ConductorFixture#OneArgTest):
248248
// org.scalatest.Outcome
249249
// Problem parsing scalatest.dotty/target/scala-3.0.0-M2/src_managed/main/org/scalatest/concurrent/ConductorFixture.scala:[602..624..3843], documentation may not be generated.
@@ -361,6 +361,8 @@ object projects:
361361
lazy val munit = SbtCommunityProject(
362362
project = "munit",
363363
sbtTestCommand = "testsJVM/test",
364+
// Hardcode the version to avoid having to deal with something set by sbt-dynver
365+
sbtPublishCommand = s"""set every version := "${Versions.munit}"; munitJVM/publishLocal; munitJS/publishLocal; munitScalacheckJVM/publishLocal; munitScalacheckJS/publishLocal; junit/publishLocal""",
364366
sbtDocCommand = "munitJVM/doc",
365367
)
366368

0 commit comments

Comments
 (0)