From 91eb89fb7c1687bd8232c6c36c66bd4c4435db52 Mon Sep 17 00:00:00 2001 From: Jeff Lewis Date: Mon, 16 Dec 2024 21:14:09 -0700 Subject: [PATCH] update versions, improve JDK version compatibility --- .mill-version | 2 +- build.sc | 19 +++++++++++++------ plugins/MDocModule.sc | 2 +- 3 files changed, 15 insertions(+), 8 deletions(-) diff --git a/.mill-version b/.mill-version index af88ba8..44ab23e 100644 --- a/.mill-version +++ b/.mill-version @@ -1 +1 @@ -0.11.1 +0.11.13 diff --git a/build.sc b/build.sc index 8023bc6..455b036 100644 --- a/build.sc +++ b/build.sc @@ -1,7 +1,7 @@ import $file.plugins.MDocModule import MDocModule.{MDocModule => MDoc} import $ivy.`com.lihaoyi::mill-contrib-bloop:` -import $ivy.`io.chris-kipp::mill-ci-release::0.1.9` +import $ivy.`io.chris-kipp::mill-ci-release::0.1.10` import $ivy.`io.github.davidgregory084::mill-tpolecat::0.3.5` import $ivy.`de.tototec::de.tobiasroeser.mill.integrationtest::0.7.1` import de.tobiasroeser.mill.integrationtest._ @@ -25,7 +25,7 @@ trait BaseScalaModule with BaseModule with ScalafmtModule with CiReleaseModule { - def scalaVersion = T.input("2.13.8") + def scalaVersion = T.input("2.13.15") def segmentsName = millModuleSegments.parts.mkString("-") @@ -42,13 +42,20 @@ trait BaseScalaModule developers = Seq(Developer(id = "lewisjkl", name = "Jeff Lewis", url = "lewisjkl.com")) ) + + // Copied from lefou's plugins to keep compatible with older java versions + override def javacOptions = { + (if (scala.util.Properties.isJavaAtLeast(9)) Seq("--release", "8") + else Seq("-source", "1.8", "-target", "1.8")) ++ + Seq("-encoding", "UTF-8", "-deprecation") + } } object Dependencies { - val osLib = ivy"com.lihaoyi::os-lib:0.8.1" + val osLib = ivy"com.lihaoyi::os-lib:0.11.3" val mill = Agg( - ivy"com.lihaoyi::mill-main:0.11.1", - ivy"com.lihaoyi::mill-main-api:0.11.1" + ivy"com.lihaoyi::mill-main:0.11.13", + ivy"com.lihaoyi::mill-main-api:0.11.13" ) } @@ -66,7 +73,7 @@ object `mill-plugin` extends BaseScalaModule { s"_mill0.11_${artifactScalaVersion()}" object itest extends MillIntegrationTestModule { - def millTestVersion = "0.11.1" + def millTestVersion = "0.11.13" def pluginsUnderTest = Seq(`mill-plugin`) } } diff --git a/plugins/MDocModule.sc b/plugins/MDocModule.sc index 4327862..c3d91dd 100644 --- a/plugins/MDocModule.sc +++ b/plugins/MDocModule.sc @@ -6,7 +6,7 @@ import os.Path // adapted from https://github.com/atooni/mill-mdoc trait MDocModule extends ScalaModule { - def scalaMdocVersion: T[String] = T("2.3.7") + def scalaMdocVersion: T[String] = T("2.6.2") def scalaMdocDep: T[Dep] = T(ivy"org.scalameta::mdoc:${scalaMdocVersion()}")