我正在尝试将现有版本从Ant + Ivy转换为Gradle,我无法在Gradle依赖项部分中研究如何表示此依赖项:
<dependency org="org" name="somelib" rev="1.0.0" conf="test-libs->runtime" force="true">
<artifact name="somelib-some-artifact-name" type="jar" conf="test-libs"/>
</dependency>
这是我走了多远:
testRuntime(group: "org", name: "somelib", version: "1.0.0", configuration: "test-libs->runtime"){
artifact {
name = 'somelib-some-artifact-name'
extension = 'jar'
type = 'jar'
}
}
任何想法声明对工件的依赖性的正确方法是什么?