@@ -43,17 +43,17 @@ trait Build {
4343object Build {
4444
4545 final case class Successful (
46- inputs : Module ,
47- options : BuildOptions ,
48- scalaParams : Option [ScalaParameters ],
49- scope : Scope ,
50- sources : Sources ,
51- artifacts : Artifacts ,
52- project : Project ,
53- output : os.Path ,
54- diagnostics : Option [Seq [(Either [String , os.Path ], bsp4j.Diagnostic )]],
55- generatedSources : Seq [GeneratedSource ],
56- isPartial : Boolean
46+ inputs : Module ,
47+ options : BuildOptions ,
48+ scalaParams : Option [ScalaParameters ],
49+ scope : Scope ,
50+ sources : Sources ,
51+ artifacts : Artifacts ,
52+ project : Project ,
53+ output : os.Path ,
54+ diagnostics : Option [Seq [(Either [String , os.Path ], bsp4j.Diagnostic )]],
55+ generatedSources : Seq [GeneratedSource ],
56+ isPartial : Boolean
5757 ) extends Build {
5858 def success : Boolean = true
5959 def successfulOpt : Some [this .type ] = Some (this )
@@ -166,24 +166,24 @@ object Build {
166166 }
167167
168168 final case class Failed (
169- inputs : Module ,
170- options : BuildOptions ,
171- scope : Scope ,
172- sources : Sources ,
173- artifacts : Artifacts ,
174- project : Project ,
175- diagnostics : Option [Seq [(Either [String , os.Path ], bsp4j.Diagnostic )]]
169+ inputs : Module ,
170+ options : BuildOptions ,
171+ scope : Scope ,
172+ sources : Sources ,
173+ artifacts : Artifacts ,
174+ project : Project ,
175+ diagnostics : Option [Seq [(Either [String , os.Path ], bsp4j.Diagnostic )]]
176176 ) extends Build {
177177 def success : Boolean = false
178178 def successfulOpt : None .type = None
179179 def outputOpt : None .type = None
180180 }
181181
182182 final case class Cancelled (
183- inputs : Module ,
184- options : BuildOptions ,
185- scope : Scope ,
186- reason : String
183+ inputs : Module ,
184+ options : BuildOptions ,
185+ scope : Scope ,
186+ reason : String
187187 ) extends Build {
188188 def success : Boolean = false
189189 def successfulOpt : None .type = None
@@ -195,9 +195,9 @@ object Build {
195195 * Using only the command-line options not the ones from the sources.
196196 */
197197 def updateInputs (
198- inputs : Module ,
199- options : BuildOptions ,
200- testOptions : Option [BuildOptions ] = None
198+ inputs : Module ,
199+ options : BuildOptions ,
200+ testOptions : Option [BuildOptions ] = None
201201 ): Module = {
202202
203203 // If some options are manually overridden, append a hash of the options to the project name
@@ -229,9 +229,7 @@ object Build {
229229 logger,
230230 options.suppressWarningOptions,
231231 options.internal.exclude
232- )
233-
234- private def build (
232+ )private def build (
235233 inputs : Module ,
236234 crossSources : CrossSources ,options : BuildOptions ,
237235 logger : Logger ,
@@ -424,17 +422,17 @@ object Build {
424422 }
425423
426424 private def build (
427- inputs : Module ,
428- sources : Sources ,
429- generatedSources : Seq [GeneratedSource ],
430- options : BuildOptions ,
431- scope : Scope ,
432- logger : Logger ,
433- buildClient : BloopBuildClient ,
434- compiler : ScalaCompiler ,
435- buildTests : Boolean ,
436- partial : Option [Boolean ],
437- actionableDiagnostics : Option [Boolean ]
425+ inputs : Module ,
426+ sources : Sources ,
427+ generatedSources : Seq [GeneratedSource ],
428+ options : BuildOptions ,
429+ scope : Scope ,
430+ logger : Logger ,
431+ buildClient : BloopBuildClient ,
432+ compiler : ScalaCompiler ,
433+ buildTests : Boolean ,
434+ partial : Option [Boolean ],
435+ actionableDiagnostics : Option [Boolean ]
438436 )(using ScalaCliInvokeData ): Either [BuildException , Build ] = either {
439437
440438 val build0 = value {
@@ -496,9 +494,9 @@ object Build {
496494 root / Constants .workspaceDirName / projectName.name / s " resources- ${scope.name}"
497495
498496 def scalaNativeSupported (
499- options : BuildOptions ,
500- inputs : Module ,
501- logger : Logger
497+ options : BuildOptions ,
498+ inputs : Module ,
499+ logger : Logger
502500 ): Either [BuildException , Option [ScalaNativeCompatibilityError ]] =
503501 either {
504502 val scalaParamsOpt = value(options.scalaParams)
@@ -635,16 +633,16 @@ object Build {
635633 }
636634
637635 def watch (
638- inputs : Module ,
639- options : BuildOptions ,
640- compilerMaker : ScalaCompilerMaker ,
641- docCompilerMakerOpt : Option [ScalaCompilerMaker ],
642- logger : Logger ,
643- crossBuilds : Boolean ,
644- buildTests : Boolean ,
645- partial : Option [Boolean ],
646- actionableDiagnostics : Option [Boolean ],
647- postAction : () => Unit = () => ()
636+ inputs : Module ,
637+ options : BuildOptions ,
638+ compilerMaker : ScalaCompilerMaker ,
639+ docCompilerMakerOpt : Option [ScalaCompilerMaker ],
640+ logger : Logger ,
641+ crossBuilds : Boolean ,
642+ buildTests : Boolean ,
643+ partial : Option [Boolean ],
644+ actionableDiagnostics : Option [Boolean ],
645+ postAction : () => Unit = () => ()
648646 )(action : Either [BuildException , Builds ] => Unit )(using ScalaCliInvokeData ): Watcher = {
649647
650648 val buildClient = BloopBuildClient .create(
@@ -839,15 +837,15 @@ object Build {
839837 * a bloop [[Project ]]
840838 */
841839 def buildProject (
842- inputs : Module ,
843- sources : Sources ,
844- generatedSources : Seq [GeneratedSource ],
845- options : BuildOptions ,
846- compilerJvmVersionOpt : Option [Positioned [Int ]],
847- scope : Scope ,
848- logger : Logger ,
849- artifacts : Artifacts ,
850- maybeRecoverOnError : BuildException => Option [BuildException ] = e => Some (e)
840+ inputs : Module ,
841+ sources : Sources ,
842+ generatedSources : Seq [GeneratedSource ],
843+ options : BuildOptions ,
844+ compilerJvmVersionOpt : Option [Positioned [Int ]],
845+ scope : Scope ,
846+ logger : Logger ,
847+ artifacts : Artifacts ,
848+ maybeRecoverOnError : BuildException => Option [BuildException ] = e => Some (e)
851849 ): Either [BuildException , Project ] = either {
852850
853851 val allSources = sources.paths.map(_._1) ++ generatedSources.map(_.generated)
@@ -1031,16 +1029,16 @@ object Build {
10311029 }
10321030
10331031 def prepareBuild (
1034- inputs : Module ,
1035- sources : Sources ,
1036- generatedSources : Seq [GeneratedSource ],
1037- options : BuildOptions ,
1038- compilerJvmVersionOpt : Option [Positioned [Int ]],
1039- scope : Scope ,
1040- compiler : ScalaCompiler ,
1041- logger : Logger ,
1042- buildClient : BloopBuildClient ,
1043- maybeRecoverOnError : BuildException => Option [BuildException ] = e => Some (e)
1032+ inputs : Module ,
1033+ sources : Sources ,
1034+ generatedSources : Seq [GeneratedSource ],
1035+ options : BuildOptions ,
1036+ compilerJvmVersionOpt : Option [Positioned [Int ]],
1037+ scope : Scope ,
1038+ compiler : ScalaCompiler ,
1039+ logger : Logger ,
1040+ buildClient : BloopBuildClient ,
1041+ maybeRecoverOnError : BuildException => Option [BuildException ] = e => Some (e)
10441042 ): Either [BuildException , (os.Path , Option [ScalaParameters ], Artifacts , Project , Boolean )] =
10451043 either {
10461044
@@ -1112,15 +1110,15 @@ object Build {
11121110 }
11131111
11141112 def buildOnce (
1115- inputs : Module ,
1116- sources : Sources ,
1117- generatedSources : Seq [GeneratedSource ],
1118- options : BuildOptions ,
1119- scope : Scope ,
1120- logger : Logger ,
1121- buildClient : BloopBuildClient ,
1122- compiler : ScalaCompiler ,
1123- partialOpt : Option [Boolean ]
1113+ inputs : Module ,
1114+ sources : Sources ,
1115+ generatedSources : Seq [GeneratedSource ],
1116+ options : BuildOptions ,
1117+ scope : Scope ,
1118+ logger : Logger ,
1119+ buildClient : BloopBuildClient ,
1120+ compiler : ScalaCompiler ,
1121+ partialOpt : Option [Boolean ]
11241122 ): Either [BuildException , Build ] = either {
11251123
11261124 if (options.platform.value == Platform .Native )
@@ -1282,14 +1280,14 @@ object Build {
12821280 else path.toString
12831281
12841282 private def jmhBuild (
1285- inputs : Module ,
1286- build : Build .Successful ,
1287- logger : Logger ,
1288- javaCommand : String ,
1289- buildClient : BloopBuildClient ,
1290- compiler : ScalaCompiler ,
1291- buildTests : Boolean ,
1292- actionableDiagnostics : Option [Boolean ]
1283+ inputs : Module ,
1284+ build : Build .Successful ,
1285+ logger : Logger ,
1286+ javaCommand : String ,
1287+ buildClient : BloopBuildClient ,
1288+ compiler : ScalaCompiler ,
1289+ buildTests : Boolean ,
1290+ actionableDiagnostics : Option [Boolean ]
12931291 )(using ScalaCliInvokeData ): Either [BuildException , Option [Build ]] = either {
12941292 val jmhProjectName = inputs.projectName.name + " _jmh"
12951293 val jmhOutputDir = inputs.workspace / Constants .workspaceDirName / jmhProjectName
0 commit comments