Skip to content

Commit

Permalink
NIT Refactor Export
Browse files Browse the repository at this point in the history
  - add explicit types where relevant
  - remove unnecessary passing of default params
  • Loading branch information
Gedochao committed May 5, 2022
1 parent a205615 commit 89607fe
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions modules/cli/src/main/scala/scala/cli/commands/Export.scala
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ object Export extends ScalaCommand[ExportOptions] {
}

// FIXME Auto-update those
def sbtBuildTool(extraSettings: Seq[String], sbtVersion: String, logger: Logger) =
def sbtBuildTool(extraSettings: Seq[String], sbtVersion: String, logger: Logger): Sbt =
Sbt(sbtVersion, extraSettings, logger)
def millBuildTool(cache: FileCache[Task], logger: Logger) = {
def millBuildTool(cache: FileCache[Task], logger: Logger): Mill = {
val launcherArtifacts = Seq(
os.rel / "mill" -> s"https://github.com/lefou/millw/raw/${Constants.lefouMillwRef}/millw",
os.rel / "mill.bat" -> s"https://github.com/lefou/millw/raw/${Constants.lefouMillwRef}/millw.bat"
Expand Down Expand Up @@ -97,9 +97,8 @@ object Export extends ScalaCommand[ExportOptions] {
val inputs = options.shared.inputsOrExit(args)
CurrentParams.workspaceOpt = Some(inputs.workspace)
val baseOptions =
options.shared.buildOptions(enableJmh = false, None, ignoreErrors = false).copy(
mainClass = options.mainClass.mainClass.filter(_.nonEmpty)
)
options.shared.buildOptions(enableJmh = false, None)
.copy(mainClass = options.mainClass.mainClass.filter(_.nonEmpty))

val (sourcesMain, optionsMain0) =
prepareBuild(inputs, baseOptions, logger, options.shared.logging.verbosity, Scope.Main)
Expand Down

0 comments on commit 89607fe

Please sign in to comment.