我试图使用gradle和这些指令指定一些jar依赖项:
http://gradle.org/docs/current/userguide/dependency_management.html#sub:file_dependencies
我有以下项目:
test
-> libs
-> svnant.jar
-> build.gradle
Run Code Online (Sandbox Code Playgroud)
其中build.gradle包含:
dependencies {
runtime files('libs/svnant.jar')
runtime fileTree(dir: 'libs', include: '*.jar')
}
Run Code Online (Sandbox Code Playgroud)
当我从windows cmd运行gradle时,我得到:
FAILURE: Build failed with an exception.
* Where:
Build file 'C:\...\test\build.gradle' line: 16
* What went wrong:
A problem occurred evaluating root project 'test'.
> Could not find method runtime() for arguments [file collection] on root project 'test'.
Run Code Online (Sandbox Code Playgroud)
我错过了什么?
| 归档时间: |
|
| 查看次数: |
5048 次 |
| 最近记录: |