diff --git a/example/scalamodule/11-repository-config/build.sc b/example/scalamodule/11-repository-config/build.sc index 965582996ba..0968e56a130 100644 --- a/example/scalamodule/11-repository-config/build.sc +++ b/example/scalamodule/11-repository-config/build.sc @@ -17,12 +17,30 @@ object foo extends ScalaModule { } } +// Mill read https://get-coursier.io/[coursier] config files automatically. +// +// It is possible to setup mirror with `mirror.properties` +// [source,properties] +// ---- +// central.from=https://repo1.maven.org/maven2 +// central.to=http://example.com:8080/nexus/content/groups/public +// ---- +// +// Note theses default config file locatations: +// +// * Linux: `~/.config/coursier/mirror.properties` +// * MacOS: `~/Library/Preferences/Coursier/mirror.properties` +// * Windows: `C:\Users\\AppData\Roaming\Coursier\config\mirror.properties` +// +// You can also set the environment variable `COURSIER_MIRRORS` or the jvm property `coursier.mirrors` to specify config file location. + + // To add custom resolvers to the initial bootstrap of the build, you can create a // custom `ZincWorkerModule`, and override the `zincWorker` method in your // `ScalaModule` by pointing it to that custom object: object CustomZincWorkerModule extends ZincWorkerModule with CoursierModule { - def repositoriesTask() = T.task { super.repositoriesTask() ++ sonatypeReleases } + def repositoriesTask = T.task { super.repositoriesTask() ++ sonatypeReleases } } object bar extends ScalaModule { @@ -37,4 +55,4 @@ object bar extends ScalaModule { > ./mill bar.compile -*/ \ No newline at end of file +*/