在 添加 maven 仓库
使用 kotlin script DSL 配置 时,添加 maven 仓库的方式如下:
repositories {
maven {
setUrl("/nexus/content/groups/public/")
}
mavenCentral()
}
它等价于以下 gradle 配置:
repositories {
maven {url '/nexus/content/groups/public/'}
mavenCentral()
}
参考资料
如何使用kotlinscript DSL()通过url添加maven存储库?
Provide maven(url: String, name: String? = null, …) shortcut