我有具有以下结构的多模块gradle这个项目:摇篮任务聚集的CheckStyle报告在多模块项目
myProject
|
|-module1
|-src
|-main
|-test
|-build.gradle
|-module2
|-src
|-main
|-test
|-build.gradle
|-build.gradle
我有以下的配置,生成的CheckStyle报告:
checkstyle {
toolVersion = '6.4.1'
configFile = rootProject.file("config/checkstyle/checkstyle.xml");
showViolations = true
ignoreFailures = true
reportsDir = file("$project.rootDir/reports/checkstyle/$project.name")
tasks.withType(Checkstyle) {
reports {
xml.enabled true
html.enabled true
}
}
}
checkstyleMain << {
ant.xslt(in: file("$project.rootDir/reports/checkstyle/$project.name/main.xml"),
style: rootProject.file('config/checkstyle-noframes-sorted.xsl'),
out: rootProject.file('config/aggregated.html'))
}
我的目标是生成汇总的checkstyle报告,其中包含来自这两个模块的信息。当我运行“gradle checkstyleMain”时,汇总的html报告仅包含来自module2的checkstyle报告信息并忽略module1信息。
我是gradle新手,如果有人能帮助我,那将会很棒。请让我知道如果你需要更多的信息