@@ -1233,7 +1233,7 @@ object Build {
12331233 libraryDependencies += (" org.scala-js" %%% " scalajs-dom" % " 1.1.0" ).cross(CrossVersion .for3Use2_13)
12341234 )
12351235
1236- def generateDocumentation (targets : Seq [String ], name : String , outDir : String , ref : String , params : Seq [String ] = Nil , usingScript : Boolean = true ) =
1236+ def generateDocumentation (targets : Seq [String ], name : String , outDir : String , ref : String , params : Seq [String ] = Nil ) =
12371237 Def .taskDyn {
12381238 val distLocation = (dist / pack).value
12391239 val projectVersion = version.value
@@ -1262,20 +1262,10 @@ object Build {
12621262 s " -source-links:github://lampepfl/dotty/ $referenceVersion" ,
12631263 ) ++ scalacOptionsDocSettings ++ revision ++ params ++ targets
12641264 import _root_ .scala .sys .process ._
1265- if (usingScript)
1266- Def .task((s " $distLocation/bin/scaladoc " +: cmd).! )
1267- else {
1268- val escapedCmd = cmd.map(arg => if (arg.contains(" " )) s """ " $arg" """ else arg)
1269- Def .task {
1270- try {
1271- (Compile / run).toTask(escapedCmd.mkString(" " , " " , " " )).value
1272- 0
1273- } catch {
1274- case _ : Throwable => 1
1275- }
1276- }
1265+ val escapedCmd = cmd.map(arg => if (arg.contains(" " )) s """ " $arg" """ else arg)
1266+ Def .task {
1267+ (Compile / run).toTask(escapedCmd.mkString(" " , " " , " " )).value
12771268 }
1278-
12791269 }
12801270
12811271 val SourceLinksIntegrationTest = config(" sourceLinksIntegrationTest" ) extend Test
@@ -1322,7 +1312,7 @@ object Build {
13221312 generateSelfDocumentation := Def .taskDyn {
13231313 generateDocumentation(
13241314 (Compile / classDirectory).value.getAbsolutePath :: Nil ,
1325- " scaladoc" , " scaladoc/output/self" , VersionUtil .gitHash
1315+ " scaladoc" , " scaladoc/output/self" , VersionUtil .gitHash, Seq ( " -usejavacp " )
13261316 )
13271317 }.value,
13281318 generateScalaDocumentation := Def .inputTaskDyn {
@@ -1363,16 +1353,16 @@ object Build {
13631353 s " -source-links:docs=github://lampepfl/dotty/master#docs " ,
13641354 " -doc-root-content" , docRootFile.toString,
13651355 " -Ydocument-synthetic-types"
1366- ), usingScript = false
1367- ))
1356+ )))
13681357 }.evaluated,
13691358
13701359 generateTestcasesDocumentation := Def .taskDyn {
13711360 generateDocumentation(
13721361 (Test / Build .testcasesOutputDir).value,
13731362 " scaladoc testcases" ,
13741363 " scaladoc/output/testcases" ,
1375- " master"
1364+ " master" ,
1365+ Seq (" -usejavacp" )
13761366 )
13771367 }.value,
13781368
0 commit comments