-
-
Save kyonmm/32b4f2b7db879e59e53d to your computer and use it in GitHub Desktop.
build
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apply plugin: 'groovy' | |
apply plugin: 'code-quality' | |
apply from:'file:./emma.gradle' | |
apply from: 'file:./findbugs.gradle' | |
apply from: 'file:./pmd.gradle' | |
defaultTasks 'clean','compile','test','jar' | |
version = '1.1' | |
def jdkVersion = 1.6 | |
def enc = 'UTF-8' | |
sourceCompatibility = jdkVersion | |
targetCompatibility = jdkVersion | |
[compileJava, compileGroovy, compileTestJava, compileTestGroovy, javadoc].each{ it.options.encoding = enc } | |
[compileGroovy, compileTestGroovy].each{ it.groovyOptions.encoding = enc } | |
[checkstyleMain, checkstyleTest, codenarcMain, codenarcTest]*.ignoreFailures = true | |
// ***** Settings for dependencies ***** | |
repositories { | |
flatDir(dirs: ["lib", "testlib"]) | |
mavenCentral() | |
} | |
dependencies { | |
emma "emma:emma:2.0.5312" | |
emma "emma:emma_ant:2.0.5312" | |
findbugsConf 'com.google.code.findbugs:findbugs:1.3.9', 'com.google.code.findbugs:findbugs-ant:1.3.9' | |
pmdConf 'pmd:pmd:4.2.5' | |
groovy module(':groovy:1.8.0'){ | |
dependency('asm:asm:3.2') | |
dependency('antlr:antlr:2.7.7') | |
dependency('commons-cli:commons-cli:1.2') | |
module(':ant:1.8.2'){ | |
dependencies(':ant-junit:1.8.2',':ant-launcher:1.8.2') | |
} | |
dependency('junit:junit:4.8.2') | |
dependency('com.google.code.hamcrest:hamcrest:all-1.3.0RC2') | |
dependency('postgresql:postgresql:9.+') | |
} | |
} | |
// ***** Settings for directories ***** | |
sourceSets { | |
main { | |
groovy { | |
srcDir 'src' | |
} | |
} | |
test { | |
groovy { | |
srcDir 'unitTest' | |
} | |
} | |
} | |
emma{ | |
reportPath = "emma" | |
} | |
task compile (dependsOn: [compileJava, compileGroovy, classes, compileTestJava, compileTestGroovy, testClasses]) << { | |
} | |
task analyze (dependsOn: [checkstyleMain, pmd, findbugs]) << { | |
} | |
task ci (dependsOn : [compile, test, analyze]) << { | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment