-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Support pure `JavaModule`s Looks like there is no need for being a `ScalaModule` at all. There is some sanity check, but it looks like not really needed. Fix #154 * Move type check outside of task * scalafmt * Add itest for java module * Use Scala 3 as default * Use optional scalaVersion via `null` for java compatibility * Fix test case * Use `null` only when calling the "Java" API * scalafmt again * .orNull * Fix unrelated issue with `ExtraCoursierSupport` for Mill 0.11 Instead of extending `ScalaModule` it should use the `bindDependency` task provided by `CoursierSupport`. Otherwise, it can be problematic in downstream modules. --------- Co-authored-by: Lorenzo Gabriele <[email protected]>
- Loading branch information
Showing
8 changed files
with
131 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import mill._ | ||
|
||
import mill.scalalib._ | ||
import mill.scalalib.publish._ | ||
import $file.plugins | ||
import com.github.lolgab.mill.mima._ | ||
|
||
trait Common extends JavaModule with PublishModule { | ||
def publishVersion = "0.0.1" | ||
def pomSettings = | ||
PomSettings("", organization = "org", "", Seq(), VersionControl(), Seq()) | ||
} | ||
object prev extends Common | ||
object curr extends Common with Mima { | ||
override def mimaPreviousArtifacts = T(Agg(ivy"org:prev:0.0.1")) | ||
override def mimaCheckDirection = CheckDirection.Backward | ||
} | ||
|
||
def prepare() = T.command { | ||
prev.publishLocal(sys.props("ivy.home") + "/local")() | ||
} | ||
|
||
def verify() = T.command { | ||
curr.mimaReportBinaryIssues()() | ||
() | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
public class Main { | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
public class Main { | ||
public static String hello() { | ||
return "Hello world!"; | ||
} | ||
} |
4 changes: 2 additions & 2 deletions
4
mill-mima-worker-api/src/com/github/lolgab/mill/mima/worker/api/MimaWorkerApi.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters