Gradle打包Jar包含依赖

增加以下配置

1
2
3
4
jar {
enabled = true
from { configurations.compileClasspath.collect { it.isDirectory() ? it : zipTree(it) } }
}
分享到