Bring `Mill` export up-to-date and support Mill. 1.0.x
I can't tell, if it's just the documentation or the whole feature, but the shown generated Mill projects looks outdated.
The page: https://scala-cli.virtuslab.org/docs/commands/export/
A screenshot:
The following issue are obvious:
- The file is
build.sc, while Mill since version 0.12 defaults tobuild.mill. Currently Mill 1.0.5 is the latest stable version - The
object test extends Testsdefinition was deprecated in Mill 0.12 and will not work for Mill 1.0. Instead it should beobject test extends ScalaTests. - The explicit addition of the dependency
os-libin thetestmodule seems redundant, since it is already defined in the main project and thetestmodule depends on the main module, so it will be resolved transitively - The mentioned bootstrap script
millwfrom the linked projectlefou/millwis archived. The script is now part of Mill itself. - While the generated
.mill-versionfile still works, using a//| mill-version: 1.0.5YAML header in thebuild.millfile should be preferred. This also shows the version to the reader of the listing, making it more obvious which Mill version is targetted by thebuild.mill.
Generally, the shown examples should mention the used versions, so the pages can age better.
It's not just the documentation - the whole Mill export is outdated.
We do produce a working build with build.sc syntax for Mill up to 0.12.15 atm, but that's that.
The feature would need quite a bit of love to support 1.0.
For more context - I consider finishing the upgrade of our build in https://github.com/VirtusLab/scala-cli/pull/3857 as the first step towards this. I do not think we will improve the export before the Scala CLI build itself is brough to 1.0.5+