@@ -6,7 +6,6 @@ import $file.project.publish, publish.{ghOrg, ghName, ScalaCliPublishModule, org
66import $file .project .settings , settings .{
77 CliLaunchers ,
88 FormatNativeImageConf ,
9- HasMacroAnnotations ,
109 HasTests ,
1110 LocalRepo ,
1211 PublishLocalNoFluff ,
@@ -42,14 +41,21 @@ object cli extends Cli
4241
4342// Publish a bootstrapped, executable jar for a restricted environments
4443object cliBootstrapped extends ScalaCliPublishModule {
45- override def jar = cli.assembly()
44+ override def unmanagedClasspath = T (cli.nativeImageClassPath())
45+ override def jar = assembly()
46+
47+ import mill .modules .Assembly
48+
49+ override def assemblyRules = Seq (
50+ Assembly .Rule .ExcludePattern (" .*\\ .tasty" ),
51+ Assembly .Rule .ExcludePattern (" .*\\ .semanticdb" )
52+ ) ++ super .assemblyRules
4653}
4754
4855object `specification-level` extends Cross [SpecificationLevel ](Scala .all: _* )
4956object `build-macros` extends BuildMacros
5057object config extends Cross [Config ](Scala .all: _* )
5158object options extends Options
52- object scalaparse extends ScalaParse
5359object directives extends Directives
5460object core extends Core
5561object `build-module` extends Build
@@ -449,10 +455,8 @@ trait Directives extends ScalaCliSbtModule with ScalaCliPublishModule with HasTe
449455 def ivyDeps = super .ivyDeps() ++ Agg (
450456 // Deps.asm,
451457 Deps .bloopConfig,
452- Deps .jsoniterCore213 ,
458+ Deps .jsoniterCore ,
453459 Deps .pprint,
454- Deps .scalametaTrees,
455- Deps .scalaparse,
456460 Deps .usingDirectives
457461 )
458462
@@ -551,11 +555,6 @@ trait Options extends ScalaCliSbtModule with ScalaCliPublishModule with HasTests
551555 }
552556}
553557
554- trait ScalaParse extends SbtModule with ScalaCliPublishModule {
555- def ivyDeps = super .ivyDeps() ++ Agg (Deps .scalaparse)
556- def scalaVersion = Scala .scala213
557- }
558-
559558trait Scala3Runtime extends SbtModule with ScalaCliPublishModule {
560559 def ivyDeps = super .ivyDeps()
561560 def scalaVersion = Scala .scala3
@@ -594,7 +593,6 @@ trait Build extends ScalaCliSbtModule with ScalaCliPublishModule with HasTests
594593 def millSourcePath = super .millSourcePath / os.up / " build"
595594 def moduleDeps = Seq (
596595 options,
597- scalaparse,
598596 directives,
599597 `scala-cli-bsp`,
600598 `test-runner`(Scala .scala213), // Depending on version compiled with Scala 3 pulls older stdlib
@@ -612,16 +610,16 @@ trait Build extends ScalaCliSbtModule with ScalaCliPublishModule with HasTests
612610 Deps .asm,
613611 Deps .collectionCompat,
614612 Deps .javaClassName,
615- Deps .jsoniterCore213,
613+ Deps .jsoniterCore,
614+ Deps .scalametaTrees,
616615 Deps .nativeTestRunner,
617616 Deps .osLib,
618617 Deps .pprint,
619618 Deps .scalaJsEnvNodeJs,
620619 Deps .scalaJsTestAdapter,
621- Deps .scalametaTrees,
622620 Deps .swoval,
623621 Deps .zipInputStream
624- ) ++ ( if (scalaVersion().startsWith( " 3 " )) Agg () else Agg ( Deps .shapeless))
622+ )
625623
626624 def repositoriesTask =
627625 T .task(super .repositoriesTask() ++ deps.customRepositories)
@@ -672,7 +670,7 @@ class SpecificationLevel(val crossScalaVersion: String) extends ScalaCliCrossSbt
672670}
673671
674672trait Cli extends SbtModule with ProtoBuildModule with CliLaunchers
675- with HasMacroAnnotations with FormatNativeImageConf {
673+ with FormatNativeImageConf {
676674
677675 def constantsFile = T .persistent {
678676 val dir = T .dest / " constants"
@@ -775,7 +773,7 @@ trait Cli extends SbtModule with ProtoBuildModule with CliLaunchers
775773 Deps .coursierPublish.exclude((organization, " config_2.13" )),
776774 Deps .jimfs, // scalaJsEnvNodeJs pulls jimfs:1.1, whose class path seems borked (bin compat issue with the guava version it depends on)
777775 Deps .jniUtils,
778- Deps .jsoniterCore213 ,
776+ Deps .jsoniterCore ,
779777 Deps .libsodiumjni,
780778 Deps .metaconfigTypesafe,
781779 Deps .pythonNativeLibs,
@@ -856,7 +854,7 @@ trait CliIntegration extends SbtModule with ScalaCliPublishModule with HasTests
856854 Deps .coursier
857855 .exclude((" com.github.plokhotnyuk.jsoniter-scala" , " jsoniter-scala-macros" )),
858856 Deps .dockerClient,
859- Deps .jsoniterCore213 ,
857+ Deps .jsoniterCore ,
860858 Deps .libsodiumjni,
861859 Deps .pprint,
862860 Deps .scalaAsync,
0 commit comments