使用配置注入时Gradle中路径的根源是什么? [英] what is the root of the path in gradle when using configuration injection?

查看:141
本文介绍了使用配置注入时Gradle中路径的根源是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

 子项目{

依赖关系{
编译fileTree(dir:'play-1.2.4 / framework / lib',include:'* .jar')
编译fileTree(dir:'webserver / play-1.2.4 / framework' ,包括:'* .jar')
}
}

我的目录结构是

 项目
子项目1
子目标2

我运行命令



gradle subproject1:依赖关系,它是EMPTY :(:(



soooo,那么相关的文件路径应该如何工作????



谢谢,
Dean

解决方案

目前,依赖关系任务仅显示存储库依赖关系。可以使用以下内容打印配置文件:

任务日志<< {
configurations.compil e.each {println it}
}


I am using configuration injection for gradle and have something like this

subprojects {

    dependencies {
        compile fileTree(dir: 'play-1.2.4/framework/lib', include: '*.jar')
        compile fileTree(dir: 'webserver/play-1.2.4/framework', include: '*.jar')
    }
}

My directory structure is

project
  subproject1
  subrpoject2

I run the command

gradle subproject1:dependencies and it is EMPTY :( :(

soooo, what should the relative file paths be so that this works????

thanks, Dean

解决方案

Currently, the dependencies task only shows repository dependencies. You can print the files that a configuration gets resolved to with:

task log << { configurations.compile.each { println it } }

这篇关于使用配置注入时Gradle中路径的根源是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆